changeset 53631:74e44ab76fa5

* vc-cvs.el (vc-cvs-annotate-extract-revision-at-line): New function.
author André Spiegel <spiegel@gnu.org>
date Tue, 20 Jan 2004 17:41:18 +0000
parents 2f41b6c48585
children a54825cb01e7
files lisp/vc-cvs.el
diffstat 1 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/vc-cvs.el	Tue Jan 20 17:39:09 2004 +0000
+++ b/lisp/vc-cvs.el	Tue Jan 20 17:41:18 2004 +0000
@@ -5,7 +5,7 @@
 ;; Author:      FSF (see vc.el for full credits)
 ;; Maintainer:  Andre Spiegel <spiegel@gnu.org>
 
-;; $Id$
+;; $Id: vc-cvs.el,v 1.66 2003/10/01 13:22:53 fx Exp $
 
 ;; This file is part of GNU Emacs.
 
@@ -625,6 +625,14 @@
 	  (beginning-of-line nil)
 	    (vc-cvs-annotate-time))))))
 
+(defun vc-cvs-annotate-extract-revision-at-line ()
+  (save-excursion
+    (beginning-of-line)
+    (if (re-search-forward "^\\([0-9]+\\.[0-9]+\\(\\.[0-9]+\\)*\\) +("
+			   (line-end-position) t)
+	(match-string-no-properties 1)
+      nil)))
+
 ;;;
 ;;; Snapshot system
 ;;;