GPM is the General Purpose Macro Generator. It has a man page
which explains what it does.
