Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

creating a mnemonic for a history command



Hallowed Zshers

This is one of the most useful incantations for me:
!?foo?:%

It searches in the history for the latest command that contains the
string `foo' and returns the token (or phrase between spaces)  in that
command.

Its a pain to type.
What is an elegant way to set up a mnemonic like say an alias or
something else to type
gimme(foo)
or
!@#foo

Anything that uses less of my limited clock cycles to do this.

🤓


Thanks
E




Messages sorted by: Reverse Date, Date, Thread, Author