emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r112378: * lisp/vc/vc-bzr.el (vc-bzr-


From: Glenn Morris
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r112378: * lisp/vc/vc-bzr.el (vc-bzr-print-log): Tweak LIMIT = 1 case.
Date: Wed, 24 Apr 2013 20:53:18 -0400
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 112378
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Wed 2013-04-24 20:53:18 -0400
message:
  * lisp/vc/vc-bzr.el (vc-bzr-print-log): Tweak LIMIT = 1 case.
modified:
  lisp/ChangeLog
  lisp/vc/vc-bzr.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2013-04-24 20:44:45 +0000
+++ b/lisp/ChangeLog    2013-04-25 00:53:18 +0000
@@ -1,3 +1,7 @@
+2013-04-25  Glenn Morris  <address@hidden>
+
+       * vc/vc-bzr.el (vc-bzr-print-log): Tweak LIMIT = 1 case.
+
 2013-04-24  Stefan Monnier  <address@hidden>
 
        * progmodes/opascal.el (opascal-set-token-property): Rename from

=== modified file 'lisp/vc/vc-bzr.el'
--- a/lisp/vc/vc-bzr.el 2013-04-24 08:13:52 +0000
+++ b/lisp/vc/vc-bzr.el 2013-04-25 00:53:18 +0000
@@ -710,12 +710,28 @@
     (apply 'vc-bzr-command "log" buffer 'async files
           (append
            (when shortlog '("--line"))
-           (when start-revision (list (format "-r..%s" start-revision)))
+           ;; The extra complications here when start-revision and limit
+           ;; are set are due to bzr log's --forward argument, which
+           ;; could be enabled via an alias in bazaar.conf.
+           ;; Svn, for example, does not have this problem, because
+           ;; it doesn't have --forward.  Instead, you can use
+           ;; svn --log -r HEAD:0 or -r 0:HEAD as you prefer.
+           ;; Bzr, however, insists in -r X..Y that X come before Y.
+           (if start-revision
+               (list (format
+                      (if (and limit (= limit 1))
+                          ;; This means we don't have to use --no-aliases.
+                          ;; Is -c any different to -r in this case?
+                          "-r%s"
+                        "-r..%s") start-revision)))
            (when limit (list "-l" (format "%s" limit)))
-           ;; This is to remove --forward, if it has been added by an alias.
            ;; There is no sensible way to combine --limit and --forward,
            ;; and it breaks the meaning of START-REVISION as the
            ;; _newest_ revision.  See bug#14168.
+           ;; Eg bzr log --forward -r ..100 --limit 50 prints
+           ;; revisions 1-50 rather than 50-100.  There
+           ;; seems no way in general to get bzr to print revisions
+           ;; 50-100 in --forward order in that case.
            ;; FIXME There may be other alias stuff we want to keep.
            ;; Is there a way to just suppress --forward?
            ;; As of 2013/4 the only caller uses limit = 1, so it does


reply via email to

[Prev in Thread] Current Thread [Next in Thread]