Added the command `magit-log-grep' (no keybinding).

This commit is contained in:
Phil Jackson 2010-03-26 16:33:32 +00:00
parent 29395e0d46
commit c7c02c2f20

View file

@ -3105,6 +3105,16 @@ Prefix arg means justify as well."
(magit-mode-init topdir 'log #'magit-refresh-log-buffer range
"--pretty=oneline" args)))
(defun magit-log-grep (str)
"Search for "
(interactive "sGrep in commit log: ")
(let ((topdir (magit-get-top-dir default-directory)))
(switch-to-buffer "*magit-log-grep*")
(magit-mode-init topdir 'log #'magit-refresh-log-buffer "HEAD"
"--pretty=oneline"
(list "-E"
(format "--grep=%s" (shell-quote-argument str))))))
(defun magit-log-long (&optional arg)
(interactive "P")
(let* ((range (if arg