2025-10-30 18:44:45 +00:00
|
|
|
* Hail Hydra?!
|
|
|
|
|
|
|
|
|
|
I find that [[https://github.com/abo-abo/hydra][Hydra]] is great for providing visual menus for tasks that might
|
|
|
|
|
otherwise be fairly unwieldy. I use them hydra's for windows, tabs, and a
|
|
|
|
|
few other things in the future perhaps.
|
|
|
|
|
|
|
|
|
|
** Tabs
|
|
|
|
|
|
|
|
|
|
Pretty simple tab hydra. Handles opening, closing, and simple navigation.
|
|
|
|
|
|
|
|
|
|
#+name: tab-hydra
|
|
|
|
|
#+begin_src emacs-lisp :tangle no
|
|
|
|
|
(defhydra hydra-tab (:color red :hint nil)
|
|
|
|
|
"
|
|
|
|
|
Movement^^ ^Modifier^
|
|
|
|
|
----------------------------------------------------------------
|
|
|
|
|
_h_ ← _n_ ew
|
|
|
|
|
_l_ → _c_ lose
|
|
|
|
|
"
|
|
|
|
|
("h" tab-previous)
|
|
|
|
|
("l" tab-next)
|
|
|
|
|
("n" tab-new)
|
|
|
|
|
("c" tab-close)
|
|
|
|
|
("SPC" nil))
|
|
|
|
|
(global-set-key (kbd "C-c t") 'hydra-tab/body)
|
|
|
|
|
#+end_src
|
|
|
|
|
|
|
|
|
|
** Pulling it all together
|
|
|
|
|
|
|
|
|
|
#+begin_src emacs-lisp
|
|
|
|
|
(use-package hydra
|
|
|
|
|
:demand t
|
|
|
|
|
:config
|
2026-02-11 05:29:40 +00:00
|
|
|
<<tab-hydra>>)
|
2025-10-30 18:44:45 +00:00
|
|
|
#+end_src
|