When opening a new file of certain types, I would like some boilerplate to be inserted. That is, when opening a buffer for a file that does not yet exist, insert some predefined text, optionally with some variable interpolation.
Things I can think of as use case:
- Insert some license text at the start
- Insert
#IF_DEFINED_FOO_H
directives in new C header files. - Insert some basic targets in a new Makefile