Bind SPC g G -> magit-status-here
And recenter after invoking it.
This commit is contained in:
parent
d8fda76c7d
commit
830e1289aa
3 changed files with 6 additions and 0 deletions
|
@ -294,6 +294,7 @@
|
|||
:desc "Magit dispatch" "/" #'magit-dispatch
|
||||
:desc "Forge dispatch" "'" #'forge-dispatch
|
||||
:desc "Magit status" "g" #'magit-status
|
||||
:desc "Magit status here" "G" #'magit-status-here
|
||||
:desc "Magit file delete" "x" #'magit-file-delete
|
||||
:desc "Magit blame" "B" #'magit-blame-addition
|
||||
:desc "Magit clone" "C" #'magit-clone
|
||||
|
|
|
@ -413,6 +413,7 @@
|
|||
:desc "Forge dispatch" "'" #'forge-dispatch
|
||||
:desc "Magit switch branch" "b" #'magit-branch-checkout
|
||||
:desc "Magit status" "g" #'magit-status
|
||||
:desc "Magit status here" "G" #'magit-status-here
|
||||
:desc "Magit file delete" "D" #'magit-file-delete
|
||||
:desc "Magit blame" "B" #'magit-blame-addition
|
||||
:desc "Magit clone" "C" #'magit-clone
|
||||
|
|
|
@ -33,6 +33,10 @@
|
|||
;; ...then refresh the rest only when we switch to them, not all at once.
|
||||
(add-hook 'doom-switch-buffer-hook #'+magit-revert-buffer-maybe-h)
|
||||
|
||||
;; Center the target file, because it's poor UX to have it at the bottom of
|
||||
;; the window after invoking `magit-status-here'.
|
||||
(advice-add #'magit-status-here :after #'doom-recenter-a)
|
||||
|
||||
;; The default location for git-credential-cache is in
|
||||
;; ~/.cache/git/credential. However, if ~/.git-credential-cache/ exists, then
|
||||
;; it is used instead. Magit seems to be hardcoded to use the latter, so here
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue