views:

2667

answers:

6

There seem to be a few camps when it comes to Emacs on OSX; Carbon versus Aqua Emacs. It seems the argument is that Aqua is a bit too far from standard Emacs and if you get too comfortable then you will have trouble using any other build of Emacs.

As a developer who has been trying to get into Emacs for a few months now, I have been using Carbon Emacs with the Emacs Starting Kit and things are going OK.

But with a Cocoa build of Emacs coming with Emacs 23 (and nightly builds), will this change anything?

Should I consider using the nightly Cocoa builds in anticipation? I'm very curious to find out the benefits and if there will be significant changes or improvements over the two main OSX Emacs apps.

+1  A: 

I've been using Aqua Emacs off and on for a while over the standard Emacs. The things I liked were just slightly better system integration... it could be that an official Cocoa build of Emacs could provide enough standard system UI integration that it would make a good default choice.

It may be worth trying the nightlies, if only to report back and help them stabilize things.

The wierdest thing for me about Aqua emacs is the default mode for a .m file is actually Matlab (which uses the same extension) instead of Obj-C mode!

One thing I'd love to see is greater XCode awareness from an emacs build (really just enhancing things like Objc-mode I guess).

Kendall Helmstetter Gelner
A: 
  • Carbon Emacs is emacs
  • Cocoa Emacs is emacs
  • X11 Emacs is emacs
  • emacs -nw (ie: command line only emacs) is also emacs
  • Even Xemacs is close enough to emacs for a beginner that you wouldn't notice the difference beyond the GUI :D

I have only used the Carbon Emacs on the mac (*), but I can not imagine there is anything in the Cocoa Emacs that is any different than any other Emacs version that can not be traced down to either a configuration or a bug!

(*) ive used the X11, command line emacs and Xemacs on linux platforms extensively though

hhafez
Aquamacs differs quite a bit from the regular emacs distributions though; a lot of keybindings are different and it insists on using its own system for storing preferences. That made me give up on it, as I try to maintain the same config for several installations of different machines and OSes.
fred-o
Keybindings can be changed by config files, no? That's what I said in my reply the only differences will be in config. There shouldn't be a fear of using one emacs over another if all you need to do to make them the same is change a config file. So reread what I said carefully ;)
hhafez
In which case emacs is entirely config files.
Singletoned
Your stretching my response a bit. Key Bindings are set in config files. Which files open in which mode are set in config files. There is nothing that anyone mentioned as a difference between Cocoa and Carbon Emacs that isn't set in a config file (very easily I must add). The defaults for each distribution are different that's all
hhafez
+10  A: 

As a long-time emacs user, I would recommand against "exotic" versions of emacs (aquamacs falls in this catagory, but this "starter kit" thing as well, and let me try to explain why), just for the sake of finger-training and brain-training also.

My argument is that you want to learn emacs once and for all, regardless of the platform (i.e. combination of OS/desktop/hardware/whatever) you'll be using emacs on. Almost every flavour of unix comes with a preinstalled emacs, so the hope is that you'll never have to resort to e.g. vi, even in the most hostile environments (for instance, editing a /etc config file on a remote HP/UX server via ssh). You'll still be able to use the old emacs 19 that sits there, and even if it does not have your config files (that is, your starter kit, your keybindings, and stuff), you'll still have say 70% of your usual editing powers at hand.

And if you find yourself often forced to edit those file on that hostile machine, you will want to mirror your .emacs config on that old emacs as much as possible. Of course, you will lose along the way some stuff that is not supported there, but again, good'ol emacs will always be emacs even if a diminished one.

Of course, if you control perfectly your working environment, e.g. if you only ever work only on your shiny mac laptop, you might want a fancier version of emacs, just because it will be easier to use Cmd-C/Cmd-V than to learn Meta-W/Ctrl-Y. And for the same reason if you develop in one language you might want to actually use a full-blown IDE with super-powers tailored for that language (e.g. Eclipse, Xcode, whatever). But you know that sometime, you will have to edit an unexpected file like a shell script, or a web page, or a Python script, or who knows what kind of text file, and this is why you want to use the omni-powerful One True Editor in the first place.

And this is the reason why I use Carbon Emacs on my shiny mac laptop: I get the exact same (emacs) features on the Ubuntu box I'm forced to use at work, using the exact same config files (handcrafted during my ten years of emacsery), and still I can feel quite confortable on other people's or other machines' emacsen.

...my two cents

Gyom
Thanks for this! Extremely insightful!
mwilliams
And with this being said, with the Cocoa build being officially bundled with Emacs 23, it's a safe bet that if I work up a nice config, it should be portable amongst other builds of Emacs, correct?
mwilliams
yes and no: first you would have to actually _extract_ the relevant parts in the mountain of lisp that comes with your emacs, but even then, your finger habits (like Cmd-C/Cmd-V, or selecting text using shift+arrow keys) would not be portable to a "hostile" environment.Type "emacs" in a mac os x terminal window to see what I mean (and imagine it could be much worse ;-)
Gyom
emacs just isn't an editor for hostile environments. That's vim. Emacs is all about customisation.
Singletoned
sure, but this is my point: if you learn emacs, you _do not_ have to resort to vi in hostile environments any more :-)
Gyom
A: 

For the subset of emacs that I use, there's very little difference between using Aquamacs and GNU emacs on a linux box. That's general text editing, lisp interaction, buffer commands, new frames, rectangular selection areas, standard emacs editing keybindings, &c. I edit my .emacs file to customize the configuration, and so forth. (I think using the graphical configuration editor does use the Aquamacs preferences, as someone else said.)

I do think the trend in recent updates has been to move away from traditional emacs style and into something more "Mac-like", it's true, and I find myself turning these options off. But, you can bend it to your will and make it more traditional.

khedron
+4  A: 

I've been building Emacs 23 from source and using it with emacs-starter-kit for a while now, and I'm definitely finding it to be a good compromise.

There's sane Mac Cmd shortcuts built into Emacs 23, and emacs-starter-kit makes it easy to customise them on a per os/machine/user basis.

I'd advise against the idea that you should learn "pure emacs" without customising it too much. If you do that then you are missing the half the point of emacs. It's the most customisable editor ever, so customise it.

If you are a sysadmin or similar, and are regularly hopping onto strange machines, then fair enough, but if you want an editor that is the same on every unix ever, then vim is a much better choice (and more widely available). (This is also a good reason for learning vim even if you use emacs as your main editor).

It is worth learning the classic emacs shortcuts before you change them though. There's usually a good reason they are the way they are. For example, if you are used to TextMate then you may be tempted to map lots of functions to complex 5 key chords of keys, but in the long run it is much easier to go with the long sequences of commands that emacs tends towards. There's much less contortion when typing. You'll even find that, with tab completion, M-x long-command-name is quicker than complex chords.

Edit:

So to actually answer your question, yes you should use the nightly builds (or better, compile them yourself, it's quite easy with a single google, and makes you feel warm inside). And keep on with emacs-starter-kit. Any problems with it, feel free to give me a shout.

Singletoned
+1, Emacs is supposed to be modified to get the most power out of it. Vim is probably a better choice for "hostile computers".
abababa22
don't get me wrong, I am not advising against customization (and all my kilobytes of .emacs can testify) ; I am advising against using exotic "non-portable" emacsen flavors.
Gyom
+2  A: 

I'm using Carbon Emacs myself and I'm moving to Cocoa port of GNU Emacs when it's released. I think that there isn't a big difference between them. I can think of some though:

  • "Cocoa" Emacs is "real" GNU Emacs instead of a fork like Carbon Emacs, so if you want to stay up to date and use the latest version, Cocoa version is always available from GNU CVS.
  • Carbon Emacs includes some elisp packages that are not included in GNU Emacs. There's a list available.
  • Cocoa port is version 23 while Carbon is 22. There might be some issues with this regarding elisp compatibility etc.

I would also stay away from Aquamacs. It's GUI seems too mouse oriented. yuck :)

abababa22