summaryrefslogtreecommitdiff
path: root/lisp/vc-rcs.el
diff options
context:
space:
mode:
authorDan Nicolaescu <dann@ics.uci.edu>2009-08-29 18:56:12 +0000
committerDan Nicolaescu <dann@ics.uci.edu>2009-08-29 18:56:12 +0000
commitdb167d28c634931c7cc72640edb23b141050fd33 (patch)
tree8889a2fefc42d731ac583e17f7afba807f197971 /lisp/vc-rcs.el
parente0840eefe151fcecd119f24665f7a7445d19892c (diff)
downloademacs-db167d28c634931c7cc72640edb23b141050fd33.tar.gz
emacs-db167d28c634931c7cc72640edb23b141050fd33.tar.bz2
emacs-db167d28c634931c7cc72640edb23b141050fd33.zip
* vc.el (vc-print-log-internal): Move RCS/CVS specific code ...
* vc-rcs.el (vc-rcs-print-log-cleanup): ... here. New function. (vc-rcs-print-log): Use it. * vc-cvs.el (vc-cvs-print-log): Use vc-rcs-print-log-cleanup.
Diffstat (limited to 'lisp/vc-rcs.el')
-rw-r--r--lisp/vc-rcs.el15
1 files changed, 14 insertions, 1 deletions
diff --git a/lisp/vc-rcs.el b/lisp/vc-rcs.el
index ffb6d21c638..95ed4ac2f64 100644
--- a/lisp/vc-rcs.el
+++ b/lisp/vc-rcs.el
@@ -538,10 +538,23 @@ directory the operation is applied to all registered files beneath it."
;;; History functions
;;;
+(defun vc-rcs-print-log-cleanup ()
+ (let ((inhibit-read-only t))
+ (goto-char (point-max))
+ (forward-line -1)
+ (while (looking-at "=*\n")
+ (delete-char (- (match-end 0) (match-beginning 0)))
+ (forward-line -1))
+ (goto-char (point-min))
+ (when (looking-at "[\b\t\n\v\f\r ]+")
+ (delete-char (- (match-end 0) (match-beginning 0))))))
+
(defun vc-rcs-print-log (files &optional buffer)
"Get change log associated with FILE. If FILE is a
directory the operation is applied to all registered files beneath it."
- (vc-do-command (or buffer "*vc*") 0 "rlog" (mapcar 'vc-name (vc-expand-dirs files))))
+ (vc-do-command (or buffer "*vc*") 0 "rlog" (mapcar 'vc-name (vc-expand-dirs files)))
+ (with-current-buffer (or buffer "*vc*")
+ (vc-rcs-print-log-cleanup)))
(defun vc-rcs-diff (files &optional oldvers newvers buffer)
"Get a difference report using RCS between two sets of files."