1

I have 3 versions of emacs on my system:

  • Emacs included by default with OS X avilable via Terminal
  • The most recent version of Emacs installed as a separate standalone app, Emacs.app on OS X
  • Lisp Box, a bundle of emacs and lisp tools in a directory, also launched via another Emacs.app

When I edit the .emacs file, it affects only the Emacs.app I installed as standalone emacs. I put this in my home dir's .emacs and it works:

(set-face-attribute 'default nil :height 200)

However this does not adjust the font size for the emacs launched from Terminal or for the Emacs.app launched from Lisp in a Box. As they are all true emacs, wouldn't they all be looking at the same .emacs file?

I have seen this question which suggests Lisp Box should also be using this .emacs file, though it is an older version of Lisp Box so perhaps that is no longer correct. However I wonder that since the Lisp Box emacs opens automatically with a lisp prompt, if somehow it has been pre-built with special rules that give it this behavior at the expense of not looking for any normal .emacs file at all? I cannot find any .el files in the Lisp Box directory so I'm not sure exactly how it receives its configuration info? It does have two .lisp files in the same directory as its Emacs.app, could they be automatically getting read upon launch of Emacs?

Community
  • 1
  • 1
johnbakers
  • 24,158
  • 24
  • 130
  • 258

1 Answers1

3

You can tell emacs what configuration file to use from the command line. So all you have to do is to see what command+arguments are you using when you invoke emacs, and change them accordingly.

For example, in lispbox.sh emacs is invoked as:

exec ${LISPBOX_HOME}/emacs-23.2/bin/emacs --no-init-file --no-site-file --eval='(progn (load "lispbox") (slime))'

So no init file (.emacs) or site configuration file. A quick and dirty fix would be to edit that file (or the one you are using to launch Lisp in a Box) to say emacs to use your configuration file. Lisp in a Box does not do that by default because being agnostic about your setup (emacs version, installed packages, ...) is what "in a box" means.

juanleon
  • 9,220
  • 30
  • 41
  • i suppose then I could have a unique .emacs file just for the Lisp Box and use that for the lispbox.sh ? – johnbakers Oct 16 '13 at 09:53
  • That would be a safe way of dealing with different emacs versions in your system. If you don't want to duplicate most of your setup, you may split your .emacs in sections and load them conditionally on every emacs you have on your system. – juanleon Oct 16 '13 at 10:05