amaranth hydras could exit via C-g (this sounds like a breaking API change so maybe it could be configurable via a parameter to defhydra)
an :upon-exit parameter could be added to defhydra similar to :post, but defined such that it doesn't execute after every head, only after actually exiting the hydra
some other method I haven't thought of
what are your thoughts on this use-case? Thanks so much!
I've got a hydra (https://melpa.org/#/symbol-navigation-hydra), and it needs to be
amaranth
so it can do some cleanup upon exit (https://github.com/bgwines/symbol-navigation-hydra/blob/e137c86d530c07438a6e42a37e054c40ab8a05fe/symbol-navigation-hydra.el#L459-L463). As a user of this package, I think it'd be dandy if I could exit the hydra viaC-g
(canonically bound todoom/escape
/keyboard-quit
/ ...) in addition to via the heads that actually exit the hydra (e.g.q
, in my case).This could be accomplished in a few ways:
amaranth
hydras could exit viaC-g
(this sounds like a breaking API change so maybe it could be configurable via a parameter todefhydra
):upon-exit
parameter could be added todefhydra
similar to:post
, but defined such that it doesn't execute after every head, only after actually exiting the hydrawhat are your thoughts on this use-case? Thanks so much!