diff options
| author | Roland McGrath | 1993-05-22 22:33:19 +0000 |
|---|---|---|
| committer | Roland McGrath | 1993-05-22 22:33:19 +0000 |
| commit | 69268c787fedcfd95955c06e655ed10bb519a978 (patch) | |
| tree | 25e950f2f0cdd1bd8112d2bfcc22eaeae94f39a1 | |
| parent | 758c80c0f394209f07624fe2342b11c1d1031cb2 (diff) | |
| download | emacs-69268c787fedcfd95955c06e655ed10bb519a978.tar.gz emacs-69268c787fedcfd95955c06e655ed10bb519a978.zip | |
(vc-comment-to-change-log): Don't take FILE argument, since
vc-update-change-log doesn't support it anyway.
Don't bind default-directory. Instead pass second arg to file-relative-name.
(vc-update-change-log): Use find-change-log instead of hardcoding.
| -rw-r--r-- | lisp/vc.el | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/lisp/vc.el b/lisp/vc.el index 605c68a5fd2..9fb699d9d03 100644 --- a/lisp/vc.el +++ b/lisp/vc.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; vc.el --- drive a version-control system from within Emacs | 1 | ;;; vc.el --- drive a version-control system from within Emacs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1992 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1992, 1993 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Eric S. Raymond <esr@snark.thyrsus.com> | 5 | ;; Author: Eric S. Raymond <esr@snark.thyrsus.com> |
| 6 | ;; Version: 5.4 | 6 | ;; Version: 5.4 |
| @@ -586,17 +586,15 @@ popped up to accept a comment." | |||
| 586 | 586 | ||
| 587 | ;;; Here is a checkin hook that may prove useful to sites using the | 587 | ;;; Here is a checkin hook that may prove useful to sites using the |
| 588 | ;;; ChangeLog facility supported by Emacs. | 588 | ;;; ChangeLog facility supported by Emacs. |
| 589 | (defun vc-comment-to-change-log (&optional file) | 589 | (defun vc-comment-to-change-log () |
| 590 | "Update change log from VC change comments entered for the current file. | 590 | "Update change log from VC change comments entered for the current file. |
| 591 | Optional FILE specifies the change log file name; see `find-change-log'. | ||
| 592 | See `vc-update-change-log'." | 591 | See `vc-update-change-log'." |
| 593 | (interactive) | 592 | (interactive) |
| 594 | (let ((log (find-change-log file))) | 593 | (let ((log (find-change-log))) |
| 595 | (if log | 594 | (if log |
| 596 | (let ((default-directory (or (file-name-directory log) | 595 | (vc-update-change-log |
| 597 | default-directory))) | 596 | (file-relative-name buffer-file-name |
| 598 | (vc-update-change-log | 597 | (file-name-directory (expand-file-name log))))))) |
| 599 | (file-relative-name buffer-file-name)))))) | ||
| 600 | 598 | ||
| 601 | (defun vc-finish-logentry (&optional nocomment) | 599 | (defun vc-finish-logentry (&optional nocomment) |
| 602 | "Complete the operation implied by the current log entry." | 600 | "Complete the operation implied by the current log entry." |
| @@ -1126,7 +1124,7 @@ From a program, any arguments are passed to the `rcs2log' script." | |||
| 1126 | (setq files (cons (file-relative-name file) files))) | 1124 | (setq files (cons (file-relative-name file) files))) |
| 1127 | (setq buffers (cdr buffers))) | 1125 | (setq buffers (cdr buffers))) |
| 1128 | files)))) | 1126 | files)))) |
| 1129 | (find-file-other-window "ChangeLog") | 1127 | (find-file-other-window (find-change-log)) |
| 1130 | (barf-if-buffer-read-only) | 1128 | (barf-if-buffer-read-only) |
| 1131 | (vc-buffer-sync) | 1129 | (vc-buffer-sync) |
| 1132 | (undo-boundary) | 1130 | (undo-boundary) |