Function: vc-bzr-diff

vc-bzr-diff is a byte-compiled function defined in vc-bzr.el.gz.

Signature

(vc-bzr-diff FILES &optional REV1 REV2 BUFFER ASYNC)

Documentation

VC bzr backend for diff.

Source Code

;; Defined in /usr/src/emacs/lisp/vc/vc-bzr.el.gz
(defun vc-bzr-diff (files &optional rev1 rev2 buffer async)
  "VC bzr backend for diff."
  (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 async 1 'async) files
           args)))