I installed Aquamacs in a fresh OS X desktop, and wanted to be able to call the program from the commandline.

Calling the file inside the app seems to work just fine:

Amoss-iMac:bin amosjyng$ /Applications/Aquamacs.app/Contents/MacOS/Aquamacs

But of course, the Emacs when called from the Terminal is still version 22. So I log in as root and try

sh-3.2# rm emacs
sh-3.2# ln -s /Applications/Aquamacs.app/Contents/MacOS/Aquamacs emacs

Using the symbolic link now, however, generates a bunch of problems:

Amoss-iMac:bin amosjyng$ emacs
Warning: arch-dependent data dir (/Users/dr/Nightly/Cocoa23ub/aquamacs-emacs.git/nextstep/Aquamacs.app/Contents/MacOS/libexec/emacs/23.3.50/i386-apple-darwin9.8.0/) does not exist.
Warning: arch-independent data dir (/Users/dr/Nightly/Cocoa23ub/aquamacs-emacs.git/nextstep/Aquamacs.app/Contents/Resources/share/emacs/23.3.50/etc/) does not exist.
Error: charsets directory (/Users/dr/Nightly/Cocoa23ub/aquamacs-emacs.git/nextstep/Aquamacs.app/Contents/Resources/share/emacs/23.3.50/etc/charsets) does not exist.
Emacs will not function correctly without the character map files.
Please check your installation!
Warning: Could not find simple.el nor simple.elc

What could I do to fix this?


So I removed the link to Aquamacs, and instead wrote a script file named emacs consisting entirely of


And now calling emacs from the Terminal works.

Does anybody have any other ways to do this?

  • You may want to add "$@" to the end /Applications/Aquamacs.app/Contents/MacOS/Aquamacs in your shell script, so that the script's command-line arguments are passed on to Emacs itself.
    – mernst
    Oct 2, 2014 at 12:10

1 Answer 1


If you only want to be able to call it from the command line, an alias would work pretty well.

Add something like:

alias emacs='/Applications/Aquamacs.app/Contents/MacOS/Aquamacs'

to your shell's startup file (~/.bash_profile or similar). (Doesn't gain you much though.)

  • Note that "alias" is also a word for a smart redirecting file in Mac Filesystems, so you should specify that you mean a shell alias. Mac aliases (which you can get from the contextual-menu::Make alias in the finder) are rather more than symbolic links. Jan 16, 2012 at 13:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .