From c0edfa75c48d19c878dc63cd0941a56653adfeb4 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 20 Jul 2007 01:22:18 +0000 Subject: [PATCH] * vc-hooks.el (vc-default-workfile-unchanged-p): Pass a list instead of a file. * vc-hg.el (vc-hg-print-log): Fix for multiple files. * vc.el: (vc-directory-exclusion-list): Add .hg and .bzr. (vc-diff-internal): Pass a list instead of a file. --- lisp/ChangeLog | 6 ++++++ lisp/vc-hg.el | 6 +----- lisp/vc-hooks.el | 4 ++-- lisp/vc.el | 10 ++++++---- 4 files changed, 15 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9f8989bcc12..6f388723a28 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2007-07-20 Dan Nicolaescu + * vc-hooks.el (vc-default-workfile-unchanged-p): Pass a list + instead of a file. + * vc-hg.el (vc-hg-print-log): Deal with multiple file arguments. (vc-hg-registered): Replace if with when. (vc-hg-state): Deal with nonexistent files and handle removed @@ -7,10 +10,13 @@ (vc-hg-dir-state, vc-hg-dired-state-info): New functions. (vc-hg-checkout): Re-enable. (vc-hg-create-repo): Fix typos. + (vc-hg-print-log): Fix for multiple files. * vc.el: Fix typo. (vc-print-log): Fix call to print-log. (vc-default-comment-history): Likewise. + (vc-directory-exclusion-list): Add .hg and .bzr. + (vc-diff-internal): Pass a list instead of a file. * vc-mcvs.el (vc-mcvs-create-repo): Fix typos. diff --git a/lisp/vc-hg.el b/lisp/vc-hg.el index d56063b996c..b2b72f38c29 100644 --- a/lisp/vc-hg.el +++ b/lisp/vc-hg.el @@ -248,11 +248,7 @@ (with-current-buffer buffer (insert "File: " (file-name-nondirectory file) "\n")) - (vc-hg-command - buffer - ;; XXX Is this stuff really needed? - (if (and (vc-stay-local-p file) (fboundp 'start-process)) 'async 0) - file "log")))) + (vc-hg-command buffer nil file "log")))) (defvar log-view-message-re) (defvar log-view-file-re) diff --git a/lisp/vc-hooks.el b/lisp/vc-hooks.el index 19b309ee203..83f9903e664 100644 --- a/lisp/vc-hooks.el +++ b/lisp/vc-hooks.el @@ -528,7 +528,7 @@ Return non-nil if FILE is unchanged." (zerop (condition-case err ;; If the implementation supports it, let the output ;; go to *vc*, not *vc-diff*, since this is an internal call. - (vc-call diff file nil nil "*vc*") + (vc-call diff (list file) nil nil "*vc*") (wrong-number-of-arguments ;; If this error came from the above call to vc-BACKEND-diff, ;; try again without the optional buffer argument (for @@ -539,7 +539,7 @@ Return non-nil if FILE is unchanged." 'diff)))) (not (eq (caddr err) 4))) (signal (car err) (cdr err)) - (vc-call diff file)))))) + (vc-call diff (list file))))))) (defun vc-workfile-version (file) "Return the repository version from which FILE was checked out. diff --git a/lisp/vc.el b/lisp/vc.el index 91caef0f4d6..d5b8dd3ba97 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -46,8 +46,9 @@ ;; This mode is fully documented in the Emacs user's manual. ;; -;; Supported version-control systems presently include CVS, RCS, GNU Arch, -;; Subversion, Meta-CVS, and SCCS (or its free replacement, CSSC). +;; Supported version-control systems presently include CVS, RCS, GNU +;; Arch, Subversion, Bzr, Mercurial, Meta-CVS, and SCCS (or its free +;; replacement, CSSC). ;; ;; Some features will not work with old RCS versions. Where ;; appropriate, VC finds out which version you have, and allows or @@ -578,7 +579,8 @@ These are passed to the checkin program by \\[vc-register]." :group 'vc :version "20.3") -(defcustom vc-directory-exclusion-list '("SCCS" "RCS" "CVS" "MCVS" ".svn" "{arch}") +(defcustom vc-directory-exclusion-list '("SCCS" "RCS" "CVS" "MCVS" ".svn" + ".hg" ".bzr" "{arch}") "List of directory names to be ignored when walking directory trees." :type '(repeat string) :group 'vc) @@ -1934,7 +1936,7 @@ actually call the backend, but performs a local diff." (error "diff failed")) (if (not vc-diff-knows-L) (setq vc-diff-knows-L 'yes))) status) - (vc-call diff (list file) rev1 rev2 "*vc-diff")))) + (vc-call diff (list file) rev1 rev2 "*vc-diff*")))) (defun vc-switches (backend op) (let ((switches -- 2.39.2