]> git.eshelyaron.com Git - emacs.git/commitdiff
(vc-print-log): Move point to the log entry of the current version.
authorAndré Spiegel <spiegel@gnu.org>
Sun, 8 Sep 1996 11:52:05 +0000 (11:52 +0000)
committerAndré Spiegel <spiegel@gnu.org>
Sun, 8 Sep 1996 11:52:05 +0000 (11:52 +0000)
lisp/vc.el

index c1d946a3ac74febdbdc019b0e88dbccde59f3180..4fb84ab1356b3527a9e7427b954d800f45dfe004 100644 (file)
@@ -1572,6 +1572,15 @@ levels in the snapshot."
        (if (looking-at "[\b\t\n\v\f\r ]+")
            (delete-char (- (match-end 0) (match-beginning 0))))
        (shrink-window-if-larger-than-buffer)
+       ;; move point to the log entry for the current version
+       (if (not (eq (vc-backend file) 'SCCS))
+           (let ((pos (re-search-forward
+                       ;; also match some context, for safety
+                       (concat "----\nrevision " (vc-workfile-version file)
+                               "\\(\tlocked by:.*\n\\|\n\\)date: ") nil t)))
+             (if pos (progn (goto-char pos)
+                            (beginning-of-line)
+                            (forward-line -1)))))
        )
     (vc-registration-error buffer-file-name)
     )