diff options
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/km-magit.el | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lisp/km-magit.el b/lisp/km-magit.el index 69f5f2b..56921e6 100644 --- a/lisp/km-magit.el +++ b/lisp/km-magit.el @@ -565,7 +565,11 @@ argument. Interactively, this can be accessed using the command (defun km/magit-log-dwim (&optional args files) (interactive (magit-log-arguments)) (let ((range - (or (magit-section-case + (or (and (use-region-p) + (prog1 (buffer-substring-no-properties + (region-beginning) (region-end)) + (deactivate-mark))) + (magit-section-case ((unpushed unpulled) (oref it value)) (tag |