diff options
author | Glenn Morris <rgm@gnu.org> | 2007-08-27 07:04:45 +0000 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2007-08-27 07:04:45 +0000 |
commit | c62a495a84df7fc23d7302657605a73eecc7f5e1 (patch) | |
tree | e2b57f1149dd669757b1759e7718424383473aa5 /lisp/vc-svn.el | |
parent | 0ddda8cd6ef917a9df612591db41334c75e8932b (diff) | |
download | emacs-c62a495a84df7fc23d7302657605a73eecc7f5e1.tar.gz |
(vc-svn-diff): If the repository version of all the files is the same
as the specified OLDVERS, do a local diff.
Diffstat (limited to 'lisp/vc-svn.el')
-rw-r--r-- | lisp/vc-svn.el | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index ddecb89d77c..0b34c30f630 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -399,6 +399,17 @@ The changes are between FIRST-VERSION and SECOND-VERSION." (defun vc-svn-diff (files &optional oldvers newvers buffer) "Get a difference report using SVN between two versions of fileset FILES." + (and oldvers + (catch 'no + (dolist (f files) + (or (equal oldvers (vc-workfile-version f)) + (throw 'no nil))) + t) + ;; Use nil rather than the current revision because svn handles + ;; it better (i.e. locally). Note that if _any_ of the files + ;; has a different revision, we fetch the lot, which is + ;; obviously sub-optimal. + (setq oldvers nil)) (let* ((switches (if vc-svn-diff-switches (vc-switches 'SVN 'diff) |