New ranged long log command.

This commit is contained in:
Phil Jackson 2010-11-01 13:49:23 +00:00
parent 6404261327
commit daa347bde9
2 changed files with 9 additions and 3 deletions

View file

@ -22,6 +22,8 @@
(actions (actions
("l" "Short" magit-log) ("l" "Short" magit-log)
("L" "Long" magit-log-long) ("L" "Long" magit-log-long)
("r l" "Ranged short" magit-log-ranged)
("r L" "Ranged long" magit-log-long-ranged)
("h" "Reflog" magit-reflog) ("h" "Reflog" magit-reflog)
("H" "Reflog on head" magit-reflog-head)) ("H" "Reflog on head" magit-reflog-head))
(switches (switches

View file

@ -3810,9 +3810,13 @@ With a non numeric prefix ARG, show all entries"
(interactive "P") (interactive "P")
(apply 'magit-display-log arg magit-custom-options)) (apply 'magit-display-log arg magit-custom-options))
(magit-define-command log-long (&optional arg) (magit-define-command magit-log-long-ranged ()
(interactive "P") (interactive)
(let* ((range (if arg (magit-log-long t))
(magit-define-command log-long (&optional ranged)
(interactive)
(let* ((range (if ranged
(magit-read-rev-range "Long log" "HEAD") (magit-read-rev-range "Long log" "HEAD")
"HEAD")) "HEAD"))
(topdir (magit-get-top-dir default-directory)) (topdir (magit-get-top-dir default-directory))