Add: feature/hydra: added git-gutter hydra
This commit is contained in:
parent
15cd2d5e0c
commit
f4b68936a3
1 changed files with 31 additions and 1 deletions
|
@ -31,7 +31,37 @@
|
|||
(when git-gutter-mode
|
||||
(git-gutter)
|
||||
nil))
|
||||
(add-hook '+evil-esc-hook #'+version-control|update-git-gutter t)))
|
||||
(add-hook '+evil-esc-hook #'+version-control|update-git-gutter t))
|
||||
|
||||
|
||||
(when (featurep! :feature hydra)
|
||||
(require 'hydra)
|
||||
(defhydra +hydra-git-gutter (:body-pre (git-gutter-mode 1)
|
||||
:hint nil)
|
||||
"
|
||||
Git gutter:
|
||||
_j_: next hunk _s_tage hunk _q_uit
|
||||
_k_: previous hunk _r_evert hunk _Q_uit and deactivate git-gutter
|
||||
^ ^ _p_opup hunk
|
||||
_h_: first hunk
|
||||
_l_: last hunk set start _R_evision
|
||||
"
|
||||
("j" (progn (git-gutter:next-hunk 1)
|
||||
(recenter)))
|
||||
("k" (progn (git-gutter:previous-hunk 1)
|
||||
(recenter)))
|
||||
("h" (progn (goto-char (point-min))
|
||||
(git-gutter:next-hunk 1)))
|
||||
("l" (progn (goto-char (point-min))
|
||||
(git-gutter:previous-hunk 1)))
|
||||
("s" git-gutter:stage-hunk)
|
||||
("r" git-gutter:revert-hunk)
|
||||
("p" git-gutter:popup-hunk)
|
||||
("R" git-gutter:set-start-revision)
|
||||
("q" nil :color blue)
|
||||
("Q" (progn (git-gutter-mode -1)
|
||||
(git-gutter:clear))
|
||||
:color blue))))
|
||||
|
||||
|
||||
(def-package! git-timemachine
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue