views:

170

answers:

6

I've started programming Erlang code that's going into production (gulp!), but I'm still using TextMate in Mac OS X, Notepad++ in Windows 7, and GEdit in Ubuntu 10.04... (I use all three at work and at home).

Emacs is the IDE of choice for programming Erlang, and I'd like to use the same editor on all three platforms. I have an idea of how to configure Emacs for programming Erlang more intelligently, but there are many choices of Emacs for each platform and I'm overwhelmed...

  • Which Emacs should I use for Mac?
  • Which Emacs should I use for Windows?
  • Which Emacs should I use for Linux?

Thanks!

+3  A: 

I use emacs23 from the gnu project(for all 3).

I decline to use Aquamacs or the other semi-standard systems, as I want to stay as "close to the metal" as possible. I also don't use UI widgets much. I decided to go with gnu emacs instead of xemacs due to the development pace; it seems that gnu emacs gets more active devepment these days, and emacswiki seems to focus on gnu emacs plugins.

For OSX; I recompile with --with-ns on ./configure and "make install" to build a .app file.

For Windows; I use the GNU binary

For Linux; I recompile from the latest released emacs.

Paul Nathan
+2  A: 

If you wish to be consistent cross-platform, then avoid Emacs variants which provide customisations not available in the others.

I'm not familiar with OSX options, but I would recommend that you use standard GNU Emacs (23.2.1 is the current release) on all three platforms.

NTEmacs is a very solid native version for Windows, or you can install the Cygwin package (along with Cygwin's X.org server).

In your init file you can then handle any system-specific config requirements you might have like this:

(when (eq system-type 'windows-nt)
  (require 'my-win32))

And everything else should be consistent, no matter where you are.

I highly recommend putting your entire config (init file and any other supporting files/packages) into version control (I use github). This makes it trivial to keep your configuration consistent between all platforms, and enables you to update the config from any one of them.

phils
+1  A: 

I write code in Emacs on all three, and I use a bunch of other software that's super-easy to install on Debian but a big pain to get working on Windows and Mac OS (and I never did get it entirely working everywhere). So I ended up installing Virtualbox, and running a virtual Debian, and Emacs inside that everywhere.

I won't claim that it's the best solution, especially if you can get your other software to work natively on Windows/Mac, but it is a solution that you might not have considered.

Ken
I do the same for a significant part of my work (Windows workstation, Linux VM). If you go down that path, I recommend running a local X server (Cygwin has one for Windows) and using it as your display for your remote Emacs. Works a treat.
phils
A: 

On mac, I use Aquamacs. It is a OS X cocoa implementation of emacs 23 so you do not have to add additional software such as fink, homebrew, or a virtual machine, to run a copy of emacs. It still uses the .emacs file for loading all the modules, so you will not have compatibility issues between versions.

You don't need any of "fink, homebrew, or a virtual machine" to run emacs on OSX. It is about a 5-step download+compile+install process, very simple for any technical person.
Paul Nathan
+2  A: 

On OSX I use this one: http://emacsformacosx.com/ it is the cocoa version and it work like a charm. And it is the standard gnu emacs

mathk
+1  A: 

Personally I avoid Aquamacs like the plague, if it was a better "Mac" style implementation of Emacs (ie. Prettier!) then I might consider it.

So a big +1 for Emacs.app (Cocoa emacs) http://emacsformacosx.com/

You can get yourself Tab bars, code folding, line-numbering etc (etc..etc) with the standard Emacs plus a few .el extensions.

I'd also recommend adding a (cond (eq system-name ...)) / (cond (eq system-type ...)) for machine/os specific settings in your .emacs config. That way you can keep a single config consistent on all your machines/platforms.

slomojo
Agreed on the conditional stuff. That can be useful if you have keybinding issues.
Paul Nathan
I use it for a few things, for example full-screen mode w32-fullscreen-on on Windows or ns-toggle-fullscreen on Mac.
slomojo