I use emacs as an editor in the command line (aliased with alias em='emacs -nw') and would like to be able to make an alias for !em to open up the file most recently opened in emacs.
I've tried alias e='!em', alias e='${!}em', alias e='${!em}', but so far can't find anything that works.
I've found some related posts about aliasing !!:
!eminstead of!!. – ilkkachu Apr 18 '17 at 14:17emcommand (although they are both in.bashrc, and I did run. .bashrcof course) – galois Apr 18 '17 at 16:39