Save Emacs Macro


M-x is command / meta

^x ( to start recording a macro
^x ) to stop recording a macro

M-x name-last-kbd-macro to name the last macro run

Open ~/.emacs, move the cursor to the bottom of the file M-x >

M-x insert-kbd-macro to insert the lisp code for a named kmacro at the cursor position.

Save the file.

In any future emacs session, M-x new-macro-name just like any emacs command.

# see above