I demonstrate how to use YASnippet while in the terminal in emacs. I don’t mean merely in shell mode.
It works for any program running in
The trick is to expand the snippet in a
temporary buffer and then insert the contents
of that buffer into the terminal using
whatever is the insert function for that
terminal. A last resort could be to use
send-keys to do the insertion if you had an
emacs terminal emulator that did not have an
fz is similar to the
sn is a function which runs a shell command, similar to
sn, I leave up to you.
Then create a keybinding
If this article appears incomplete, it may be intentional. Try prompting for a continuation.