Merge branch 'fancy-log-output'.

This commit is contained in:
Phil Jackson 2010-03-16 13:34:44 +00:00
parent bf42bf872a
commit 0074a3185c

View file

@ -2915,8 +2915,11 @@ Prefix arg means justify as well."
(when (magit-section-p stash) (when (magit-section-p stash)
(setq stash (magit-section-info stash))) (setq stash (magit-section-info stash)))
(let ((dir default-directory) (let ((dir default-directory)
(buf (get-buffer-create "*magit-stash*"))) (buf (get-buffer-create "*magit-stash*"))
(cond ((equal magit-currently-shown-stash stash) (stash-id (magit-git-string "rev-list" "-1" stash)))
(cond ((and (equal magit-currently-shown-stash stash-id)
(with-current-buffer buf
(> (length (buffer-string)) 1)))
(let ((win (get-buffer-window buf))) (let ((win (get-buffer-window buf)))
(cond ((not win) (cond ((not win)
(display-buffer buf)) (display-buffer buf))
@ -2924,7 +2927,7 @@ Prefix arg means justify as well."
(with-selected-window win (with-selected-window win
(funcall scroll)))))) (funcall scroll))))))
(t (t
(setq magit-currently-shown-stash stash) (setq magit-currently-shown-stash stash-id)
(display-buffer buf) (display-buffer buf)
(with-current-buffer buf (with-current-buffer buf
(set-buffer buf) (set-buffer buf)
@ -3304,7 +3307,7 @@ Prefix arg means justify as well."
(pop-to-buffer "*magit-commit*")) (pop-to-buffer "*magit-commit*"))
((stash) ((stash)
(magit-show-stash info) (magit-show-stash info)
(pop-to-buffer "*magit-diff*")) (pop-to-buffer "*magit-stash*"))
((topic) ((topic)
(magit-checkout info)))) (magit-checkout info))))