Autoload defhydra, remove unnecessary requires
This commit is contained in:
parent
e6658b7d8e
commit
91ff3afcd6
2 changed files with 40 additions and 40 deletions
|
@ -1,7 +1,7 @@
|
||||||
;;; feature/hydra/config.el -*- lexical-binding: t; -*-
|
;;; feature/hydra/config.el -*- lexical-binding: t; -*-
|
||||||
|
|
||||||
(def-package! hydra
|
(def-package! hydra
|
||||||
:commands (+hydra-zoom/body +hydra-window/body)
|
:commands (+hydra-zoom/body +hydra-window/body defhydra)
|
||||||
:config
|
:config
|
||||||
(defhydra +hydra-zoom (:hint t :color red)
|
(defhydra +hydra-zoom (:hint t :color red)
|
||||||
"zoom"
|
"zoom"
|
||||||
|
@ -47,48 +47,49 @@
|
||||||
("q" nil)))
|
("q" nil)))
|
||||||
|
|
||||||
|
|
||||||
(when (featurep! :completion ivy)
|
(def-package! ivy-hydra
|
||||||
(def-package! ivy-hydra
|
:when (featurep! :completion ivy)
|
||||||
:config
|
:after hydra
|
||||||
(define-key ivy-mode-map (kbd "C-o")
|
:config
|
||||||
(defhydra coo-ivy (:hint nil :color pink)
|
(define-key ivy-mode-map (kbd "C-o")
|
||||||
"
|
(defhydra coo-ivy (:hint nil :color pink)
|
||||||
|
"
|
||||||
Move ^^^^^^^^^^ | Call ^^^^ | Cancel^^ | Options^^ | Action _w_/_s_/_a_: %s(ivy-action-name)
|
Move ^^^^^^^^^^ | Call ^^^^ | Cancel^^ | Options^^ | Action _w_/_s_/_a_: %s(ivy-action-name)
|
||||||
----------^^^^^^^^^^-+--------------^^^^-+-------^^-+--------^^-+---------------------------------
|
----------^^^^^^^^^^-+--------------^^^^-+-------^^-+--------^^-+---------------------------------
|
||||||
_g_ ^ ^ _k_ ^ ^ _u_ | _f_orward _o_ccur | _i_nsert | _c_alling: %-7s(if ivy-calling \"on\" \"off\") _C_ase-fold: %-10`ivy-case-fold-search
|
_g_ ^ ^ _k_ ^ ^ _u_ | _f_orward _o_ccur | _i_nsert | _c_alling: %-7s(if ivy-calling \"on\" \"off\") _C_ase-fold: %-10`ivy-case-fold-search
|
||||||
^↨^ _h_ ^+^ _l_ ^↕^ | _RET_ done ^^ | _q_uit | _m_atcher: %-7s(ivy--matcher-desc) _t_runcate: %-11`truncate-lines
|
^↨^ _h_ ^+^ _l_ ^↕^ | _RET_ done ^^ | _q_uit | _m_atcher: %-7s(ivy--matcher-desc) _t_runcate: %-11`truncate-lines
|
||||||
_G_ ^ ^ _j_ ^ ^ _d_ | _TAB_ alt-done ^^ | ^ ^ | _<_/_>_: shrink/grow
|
_G_ ^ ^ _j_ ^ ^ _d_ | _TAB_ alt-done ^^ | ^ ^ | _<_/_>_: shrink/grow
|
||||||
"
|
"
|
||||||
;; arrows
|
;; arrows
|
||||||
("j" ivy-next-line)
|
("j" ivy-next-line)
|
||||||
("k" ivy-previous-line)
|
("k" ivy-previous-line)
|
||||||
("l" ivy-alt-done)
|
("l" ivy-alt-done)
|
||||||
("h" ivy-backward-delete-char)
|
("h" ivy-backward-delete-char)
|
||||||
("g" ivy-beginning-of-buffer)
|
("g" ivy-beginning-of-buffer)
|
||||||
("G" ivy-end-of-buffer)
|
("G" ivy-end-of-buffer)
|
||||||
("d" ivy-scroll-up-command)
|
("d" ivy-scroll-up-command)
|
||||||
("u" ivy-scroll-down-command)
|
("u" ivy-scroll-down-command)
|
||||||
("e" ivy-scroll-down-command)
|
("e" ivy-scroll-down-command)
|
||||||
;; actions
|
;; actions
|
||||||
("q" keyboard-escape-quit :exit t)
|
("q" keyboard-escape-quit :exit t)
|
||||||
("C-g" keyboard-escape-quit :exit t)
|
("C-g" keyboard-escape-quit :exit t)
|
||||||
("<escape>" keyboard-escape-quit :exit t)
|
("<escape>" keyboard-escape-quit :exit t)
|
||||||
("C-o" nil)
|
("C-o" nil)
|
||||||
("i" nil)
|
("i" nil)
|
||||||
("TAB" ivy-alt-done :exit nil)
|
("TAB" ivy-alt-done :exit nil)
|
||||||
("C-j" ivy-alt-done :exit nil)
|
("C-j" ivy-alt-done :exit nil)
|
||||||
;; ("d" ivy-done :exit t)
|
;; ("d" ivy-done :exit t)
|
||||||
("RET" ivy-done :exit t)
|
("RET" ivy-done :exit t)
|
||||||
("C-m" ivy-done :exit t)
|
("C-m" ivy-done :exit t)
|
||||||
("f" ivy-call)
|
("f" ivy-call)
|
||||||
("c" ivy-toggle-calling)
|
("c" ivy-toggle-calling)
|
||||||
("m" ivy-toggle-fuzzy)
|
("m" ivy-toggle-fuzzy)
|
||||||
(">" ivy-minibuffer-grow)
|
(">" ivy-minibuffer-grow)
|
||||||
("<" ivy-minibuffer-shrink)
|
("<" ivy-minibuffer-shrink)
|
||||||
("w" ivy-prev-action)
|
("w" ivy-prev-action)
|
||||||
("s" ivy-next-action)
|
("s" ivy-next-action)
|
||||||
("a" ivy-read-action)
|
("a" ivy-read-action)
|
||||||
("t" (setq truncate-lines (not truncate-lines)))
|
("t" (setq truncate-lines (not truncate-lines)))
|
||||||
("C" ivy-toggle-case-fold)
|
("C" ivy-toggle-case-fold)
|
||||||
|
|
||||||
("o" ivy-occur :exit t)))))
|
("o" ivy-occur :exit t))))
|
||||||
|
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
|
|
||||||
(when (featurep! :feature hydra)
|
(when (featurep! :feature hydra)
|
||||||
(require 'hydra)
|
|
||||||
(defhydra +hydra-git-gutter (:body-pre (git-gutter-mode 1)
|
(defhydra +hydra-git-gutter (:body-pre (git-gutter-mode 1)
|
||||||
:hint nil)
|
:hint nil)
|
||||||
"
|
"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue