Be more key map specific

This commit is contained in:
Gerard Vermeulen 2022-04-17 16:11:05 +02:00
parent 51512fcb95
commit a9e1ed2ec1
1 changed files with 5 additions and 4 deletions

View File

@ -863,7 +863,7 @@ Listing [[lst:configure-consult]] configures =consult=.
|-------------------------------+---------------------+------------------------|
| command | keys | key map |
|-------------------------------+---------------------+------------------------|
| =consult-apropos= | {{{kbd(<help> a)}}} | =global-map= |
| =consult-apropos= | {{{kbd(<help> a)}}} | =help-map= |
| =consult-bookmark= | {{{kbd(C-x r b)}}} | =ctl-x-r-keymap= |
| =consult-buffer-other-frame= | {{{kbd(C-x 5 b)}}} | =ctl-x-5-keymap= |
| =consult-buffer-other-window= | {{{kbd(C-x 4 b)}}} | =ctl-x-4-keymap= |
@ -911,9 +911,11 @@ Listing [[lst:configure-consult]] configures =consult=.
(when (fboundp 'consult-apropos)
(custom-set-variables
'(consult-project-root-function #'vc-root-dir))
;; C-c bindings (mode-specific-map)
;; C-c bindings (current-global-map)
(global-set-key (kbd "C-c h") #'consult-history)
(global-set-key (kbd "C-c m") #'consult-mode-command)
;; C-h bindings (help-map)
(define-key help-map (kbd "a") #'consult-apropos)
;; C-x bindings (ctl-x-map)
(define-key ctl-x-map (kbd "M-:") #'consult-complex-command)
(define-key ctl-x-map (kbd "b") #'consult-buffer)
@ -936,9 +938,8 @@ Listing [[lst:configure-consult]] configures =consult=.
(define-key search-map (kbd "l") #'consult-line)
(define-key search-map (kbd "m") #'consult-multi-occur)
(define-key search-map (kbd "u") #'consult-focus-lines)
;; Other bindings
;; Other bindings (current-global-map)
(global-set-key (kbd "M-y") #'consult-yank-pop)
(global-set-key (kbd "<help> a") #'consult-apropos)
;; Tweak functions
(advice-add 'completing-read-multiple
:override #'consult-completing-read-multiple))