emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] scratch/gited 843b867: gited-list-branches: Move to current branc


From: Tino Calancha
Subject: [elpa] scratch/gited 843b867: gited-list-branches: Move to current branch only when it's shown
Date: Fri, 2 Jun 2017 03:07:10 -0400 (EDT)

branch: scratch/gited
commit 843b867b56e0e730204ed13788fdd2876c088027
Author: Tino Calancha <address@hidden>
Commit: Tino Calancha <address@hidden>

    gited-list-branches: Move to current branch only when it's shown
    
    * gited.el (gited-list-branches): Move point to `gited-current-branch'
    only when it's shown in the gited buffer.
---
 packages/gited/gited.el | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/packages/gited/gited.el b/packages/gited/gited.el
index 86e2eb4..0f91912 100644
--- a/packages/gited/gited.el
+++ b/packages/gited/gited.el
@@ -10,9 +10,9 @@
 ;; Compatibility: GNU Emacs: 24.4
 ;; Version: 0.2.0
 ;; Package-Requires: ((emacs "24.4") (cl-lib "0.5"))
-;; Last-Updated: Fri Jun 02 11:10:51 JST 2017
+;; Last-Updated: Fri Jun 02 15:53:47 JST 2017
 ;;           By: calancha
-;;     Update #: 635
+;;     Update #: 636
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;;
@@ -3157,8 +3157,11 @@ in the active region."
         (setq buffer-invisibility-spec (list t)))
       (gited-tabulated-list-entries)
       (tabulated-list-print)
-      (gited-goto-branch gited-current-branch)
-      (gited-fontify-current-branch)
+      ;; Go to `gited-current-branch' when it is shown.
+      (when (assoc gited-current-branch
+                   (mapcar (lambda (x) (cdr (cddr x))) gited-branch-alist))
+        (gited-goto-branch gited-current-branch)
+        (gited-fontify-current-branch))
       (unless gited--hide-details-set
         (or gited-verbose (gited-hide-details-mode 1))
         (setq gited--hide-details-set t)))))



reply via email to

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