Since the update to macOS Catalina, I installed Emacs separately using brew cask install emacs
. Now when I type emacs
in Terminal, Emacs is opened in a separate window with a GUI (the Emacs.app?). How do I get back to just a plain old Emacs in the terminal with no GUI?
2 Answers
You should be able to run
emacs -nw
(„no window“) to prevent it from opening a new window.
Updated answer for macOS 10.15+ (Catalina) or using the zsh shell:
emacs -nw
still works, but if you want to make an alias for this (so you don't have to type it in every time) complete the following steps:
1) Navigate to your home directory using cd ~
2) Open up the .zshrc file (its okay if it doesn't yet exist) with emacs -nw .zshrc
3) Type: alias emacs='emacs -nw'
(make sure there are no spaces on either side of the equals sign or it will not work)
4) Quit Terminal, restart it, and emacs should now default to the in-Terminal/no-GUI version.
emacs -nw
help?alias emacs = 'emacs -nw'
to my .bash_profile and now I have the old behavior. Thank you! Incidentally,man emacs
does not have an entry.