Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
27bbeb29
Commit
27bbeb29
authored
Jan 27, 2011
by
Deniz Dogan
Browse files
* vc/vc-bzr.el (vc-bzr-diff): Don't pass --diff-options unless
there are some diff switches.
parent
89fdaac7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
12 deletions
+21
-12
lisp/ChangeLog
lisp/ChangeLog
+5
-0
lisp/vc/vc-bzr.el
lisp/vc/vc-bzr.el
+16
-12
No files found.
lisp/ChangeLog
View file @
27bbeb29
2011-01-27 Deniz Dogan <deniz.a.m.dogan@gmail.com>
* vc/vc-bzr.el (vc-bzr-diff): Don't pass --diff-options unless
there are some diff switches.
2011-01-27 Stefan Monnier <monnier@iro.umontreal.ca>
* progmodes/ruby-mode.el (ruby-syntax-propertize-function):
...
...
lisp/vc/vc-bzr.el
View file @
27bbeb29
...
...
@@ -674,18 +674,22 @@ REV non-nil gets an error."
(defun vc-bzr-diff (files &optional rev1 rev2 buffer)
"VC bzr backend for diff."
;; `bzr diff' exits with code 1 if diff is non-empty.
(apply #'vc-bzr-command "diff" (or buffer "*vc-diff*")
(if vc-disable-async-diff 1 'async) files
"--diff-options" (mapconcat 'identity
(vc-switches 'bzr 'diff)
" ")
;; This `when' is just an optimization because bzr-1.2 is *much*
;; faster when the revision argument is not given.
(when (or rev1 rev2)
(list "-r" (format "%s..%s"
(or rev1 "revno:-1")
(or rev2 ""))))))
(let* ((switches (vc-switches 'bzr 'diff))
(args
(append
;; Only add --diff-options if there are any diff switches.
(unless (zerop (length switches))
(list "--diff-options" (mapconcat 'identity switches " ")))
;; This `when' is just an optimization because bzr-1.2 is *much*
;; faster when the revision argument is not given.
(when (or rev1 rev2)
(list "-r" (format "%s..%s"
(or rev1 "revno:-1")
(or rev2 "")))))))
;; `bzr diff' exits with code 1 if diff is non-empty.
(apply #'vc-bzr-command "diff" (or buffer "*vc-diff*")
(if vc-disable-async-diff 1 'async) files
args)))
;; FIXME: vc-{next,previous}-revision need fixing in vc.el to deal with
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment