472 |
;; Check that dir is under CVS control. |
;; Check that dir is under CVS control. |
473 |
(unless (file-directory-p dir) |
(unless (file-directory-p dir) |
474 |
(error "%s is not a directory" dir)) |
(error "%s is not a directory" dir)) |
475 |
(unless (or noexist (file-directory-p (expand-file-name "CVS" dir))) |
(unless (or noexist (file-directory-p (expand-file-name "CVS" dir)) |
476 |
|
(file-expand-wildcards (expand-file-name "*/CVS" dir))) |
477 |
(error "%s does not contain CVS controlled files" dir)) |
(error "%s does not contain CVS controlled files" dir)) |
478 |
|
|
479 |
(set-buffer cvsbuf) |
(set-buffer cvsbuf) |
1378 |
;;;; |
;;;; |
1379 |
|
|
1380 |
(defun-cvs-mode (cvs-mode-insert . NOARGS) (file) |
(defun-cvs-mode (cvs-mode-insert . NOARGS) (file) |
1381 |
"Insert an entry for a specific file." |
"Insert an entry for a specific file into the current listing. |
1382 |
|
This is typically used if the file is up-to-date (or has been added |
1383 |
|
outside of PCL-CVS) and one wants to do some operation on it." |
1384 |
(interactive |
(interactive |
1385 |
(list (read-file-name |
(list (read-file-name |
1386 |
"File to insert: " |
"File to insert: " |
1983 |
(defun-cvs-mode cvs-mode-add-change-log-entry-other-window () |
(defun-cvs-mode cvs-mode-add-change-log-entry-other-window () |
1984 |
"Add a ChangeLog entry in the ChangeLog of the current directory." |
"Add a ChangeLog entry in the ChangeLog of the current directory." |
1985 |
(interactive) |
(interactive) |
1986 |
(let* ((fi (cvs-mode-marked nil nil :one t)) |
(dolist (fi (cvs-mode-marked nil nil)) |
1987 |
(default-directory (cvs-expand-dir-name (cvs-fileinfo->dir fi))) |
(let ((default-directory (cvs-expand-dir-name (cvs-fileinfo->dir fi))) |
1988 |
(buffer-file-name (expand-file-name (cvs-fileinfo->file fi)))) |
(buffer-file-name (expand-file-name (cvs-fileinfo->file fi)))) |
1989 |
(kill-local-variable 'change-log-default-name) |
(kill-local-variable 'change-log-default-name) |
1990 |
(add-change-log-entry-other-window))) |
(save-excursion (add-change-log-entry-other-window))))) |
1991 |
|
|
1992 |
;; interactive commands to set optional flags |
;; interactive commands to set optional flags |
1993 |
|
|
1996 |
(interactive |
(interactive |
1997 |
(list (completing-read |
(list (completing-read |
1998 |
"Which flag: " |
"Which flag: " |
1999 |
(mapcar 'list '("cvs" "diff" "update" "status" "log" "tag" ;"rtag" |
'("cvs" "diff" "update" "status" "log" "tag" ;"rtag" |
2000 |
"commit" "remove" "undo" "checkout")) |
"commit" "remove" "undo" "checkout") |
2001 |
nil t))) |
nil t))) |
2002 |
(let* ((sym (intern (concat "cvs-" flag "-flags")))) |
(let* ((sym (intern (concat "cvs-" flag "-flags")))) |
2003 |
(let ((current-prefix-arg '(16))) |
(let ((current-prefix-arg '(16))) |