[F] TidBITS  / TidBITS  / TidBITS Talk  /

Emacs on the Mac

[gamcall]gamcall - 04:39am Apr 5, 2007 PST
Glen A McAllister

Posted by: Chris Page Date: Apr 4, 2007. (And -- on a serious note -- I find emacs's HTML editing mode a lot more helpful than BBEdit's.)


I know emacs is included as part of the Darwin Unix installation (which), but I was wondering if & how you use it? Do you use it in X-mode? Or is there an OSX native version you favour? A quick Google revealed there are a few of these kicking around.

Regards,

GAM


Mark as Read
  OutlineAll MessagesOlder MessagesOldest MessagesNewest MessagesNewer Messages

johnbaxterlists (apparently) - Apr 6, 2007 7:45 am (#1 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 655
Re: Emacs on the Mac



On Apr 5, 2007, at 4:39 AM, gamcall wrote:

> I know emacs is included as part of the Darwin Unix installation
> (which), but I was wondering if & how you use it? Do you use it in
> X-mode? Or is there an OSX native version you favour? A quick
> Google revealed there are a few of these kicking around.

Open a window in Terminal. Type the command
emacs

That gives you an introductory spiel which goes away if you type
something. Two lines from that spiel:

Exit Emacs C-x C-c
Get a tutorial M-x help-with-tutorial


C-x means Control-x
M-x means Meta-x which really means Escape (labeled "esc" on current
keyboards) FOLLOWED BY x. Meta-x then accepts a typed command...in
this case "help-with-tutorial". I do recommend working through the
tutorial (it's lighter than the 500+ page O'Reilly book "Learning GNU
Emacs"). You don't HAVE to learn all the available emacs commands--
I've gotten by just fine for years with the dozen--perhaps score--
that I know. I look up the others when I need them.


If you prefer, you indeed can do the same thing in the terminal
program that is used with X11 on the Mac. But you don't need X11 to
use emacs.

To confuse matters further, there is at least one nice GUI wrapping
of emacs for the Mac: <http://aquamacs.org/>

I have it--I don't use it, but you might like it.

   --John


Lewis Butler (apparently) - Apr 6, 2007 7:45 am (#2 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 1060
Re: Emacs on the Mac

On 5-Apr-2007, at 05:39, gamcall wrote:
> I know emacs is included as part of the Darwin Unix installation

Really?

Waddayaknow!

OK, now how the hell do I get out of it? ;)

> (which), but I was wondering if & how you use it? Do you use it in
> X-mode? Or is there an OSX native version you favour? A quick
> Google revealed there are a few of these kicking around.

Aquaemacs is the only one I've heard of people using

<http://aquamacs.org/>

David Weintraub (apparently) - Apr 6, 2007 7:45 am (#3 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 232
Re: Emacs on the Mac

> I know emacs is included as part of the Darwin Unix installation
> (which), but I was wondering if & how you use it? Do you use it in
> X-mode? Or is there an OSX native version you favour? A quick
> Google revealed there are a few of these kicking around.

Emacs can be executed right from Terminal. Bring up a terminal window
and type "emacs". No need for X11. In fact, I couldn't find the X11
version of Emacs (normally called xmacs) on my Mac although emacs was
sitting there in /usr/bin.

(To get out of Emacs, you type Ctrl-C Ctrl-X.)

--
David Weintraub
davidweintraubworld.net
davidweintraub.name



Mike Cohen (apparently) - Apr 6, 2007 11:14 am (#4 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 133
Re: Emacs on the Mac

On 4/6/07, johnbaxterlistsmac.com <johnbaxterlistsmac.com> wrote:

> C-x means Control-x
> M-x means Meta-x which really means Escape (labeled "esc" on current
> keyboards) FOLLOWED BY x. Meta-x then accepts a typed command...in
> this case "help-with-tutorial". I do recommend working through the
> tutorial (it's lighter than the 500+ page O'Reilly book "Learning GNU
> Emacs"). You don't HAVE to learn all the available emacs commands--
> I've gotten by just fine for years with the dozen--perhaps score--
> that I know. I look up the others when I need them.

In Terminal's window preferences, under keyboard you can have it use
Option as the meta key. In that case, rather than typing Esc-X you can
hit Option-X. Since the page up command is Meta-V, that makes it a lot
easier to use.

johnbaxterlists (apparently) - Apr 6, 2007 11:14 am (#5 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 655
Re: Emacs on the Mac



On Apr 6, 2007, at 7:45 AM, David Weintraub wrote:

>
> Emacs can be executed right from Terminal. Bring up a terminal window
> and type "emacs". No need for X11. In fact, I couldn't find the X11
> version of Emacs (normally called xmacs) on my Mac although emacs was
> sitting there in /usr/bin.

Plain emacs runs fine under X11, but lacks the extra bells and
whistles that xemacs provides. (There are enough bells and whistles
in emacs to keep one perplexed for years.)

   --John


rjk (apparently) - Apr 6, 2007 11:14 am (#6 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 6
Re: Emacs on the Mac

On Fri, Apr 06, 2007 at 07:45:25AM -0700, David Weintraub wrote:
>
> (To get out of Emacs, you type Ctrl-C Ctrl-X.)

Actually, it's Ctrl-X Ctrl-C.

Ctrl-X in emacs is a prefix for many commands, such as:
Ctrl-X Ctrl-S (save buffer)
Ctrl-X Ctrl-F (find file, i.e. open...)
Ctrl-X Ctrl-W (write file, i.e. save as...)
Ctrl-X k (kill buffer, i.e. close)
Ctrl-X i (insert file)


Ronald

schinder (apparently) - Apr 6, 2007 3:26 pm (#7 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 115
Re: Emacs on the Mac

johnbaxterlistsmac.com wrote:
>
> On Apr 6, 2007, at 7:45 AM, David Weintraub wrote:
>
>>
>> Emacs can be executed right from Terminal. Bring up a terminal window
>> and type "emacs". No need for X11. In fact, I couldn't find the X11
>> version of Emacs (normally called xmacs) on my Mac although emacs was
>> sitting there in /usr/bin.
>
> Plain emacs runs fine under X11, but lacks the extra bells and
> whistles that xemacs provides. (There are enough bells and whistles
> in emacs to keep one perplexed for years.)

xemacs <http://xemacs.org> is a fork of GNU emacs; the fork occurred
many years ago. Both xemacs and GNU emacs can be used with and without
X11. /usr/bin/emacs on Mac OS X isn't X11 aware, but you can easily
install an X11 aware emacs using fink <http://finkproject.org> into
/sw/bin. I don't think it's possible for mere mortals to compile GNU
emacs from source on Mac OS X (been years since I tried, though, but I'm
not aware of a new version of GNU emacs being released in a long time).
 It's easily possible to compile xemacs on your own from source on Mac OS X.

I think one of the motivations for the fork was the fact that GNU emacs
development was (is?) glacially slow. xemacs development seems to be
pretty active. As John says, xemacs has even more bells and whistles
than emacs, including a nice interface for installing extra modes and
modules. I have both installed on my Macs, but I usually use emacs,
simply because I don't like the look of xemacs in X11.

As for Aqua aware emacs, I've been using
<http://homepage.mac.com/zenitani/emacs-e.html>. It works as emacs
should, but because of the extra effort of using the GUI to start it up,
I usually just use /sw/bin/emacs on the command line in an xterm. (I
always have a few xterms around.)

--
Paul Schinder
schinderpobox.com

John C. Welch (apparently) - Apr 6, 2007 3:26 pm (#8 Total: 11)  

Reply to this message
via email  

Photo of Author
Posts: 834
Re: Emacs on the Mac

On 4/6/07 13:14 PM, "johnbaxterlistsmac.com" <johnbaxterlistsmac.com>
wrote:

>> Emacs can be executed right from Terminal. Bring up a terminal window
>> and type "emacs". No need for X11. In fact, I couldn't find the X11
>> version of Emacs (normally called xmacs) on my Mac although emacs was
>> sitting there in /usr/bin.
>
> Plain emacs runs fine under X11, but lacks the extra bells and
> whistles that xemacs provides. (There are enough bells and whistles
> in emacs to keep one perplexed for years.)

Is it possible for there to exist a bell or whistle that is NOT in emacs? I
would not even blink were you to show me emacs-cad

--
John C. Welch Writer/Analyst
Bynkii.com Mac and other opinions
jwelchbynkii.com



gamcall - Apr 9, 2007 12:55 pm (#9 Total: 11)  

Reply to this message
Glen A McAllister  

Photo of Author
Posts: 42
Re: Emacs on the Mac

On Apr 5, 2007, at 4:39 AM, gamcall wrote:


> I know emacs is included as part of the Darwin Unix installation > (which), but I was wondering if & how you use it? Do you use it in > X-mode? Or is there an OSX native version you favour? A quick > Google revealed there are a few of these kicking around.


Open a window in Terminal. Type the command emacs...


I should've made it clearer that I intended the question to be for a previous poster (who'd praised emacs' HTML features as vs. BBEdit's) but to be open to the group. This would've been harder to pick as the moderator made a new thread out of my original reply to the (last?) 'We Are the Past' post.

So, 'how *you* use it', wasn't meant to be 'how *do* you use it'. I didn't mean it to become a basic emacs tutorial. I mean - if I can type 'which emacs' at the prompt (to ascertain its existence in the installation), I can certainly type 'emacs' once I know it's there, or 'man emacs' if I'm not sure how to use it. But thanks anyway.

Regards,

GAM

hibbert - Apr 11, 2007 4:25 am (#10 Total: 11)  

Reply to this message
 

Photo of Author
Posts: 1
Re: Emacs on the Mac

I've been using Emacs in various flavors since 1979. I've used a variety of emacs versions on the Mac, but mostly xemacs until recently. With my new MacBook, I discovered that none of the emacs codelines that I was used to seemed to install easily or run well in a mouse-sensitive fashion. (Running emacs in a terminal window gets you an editor that doesn't notice the mouse. Emacs works as well as anything in that mode, but that's no reason not to use a mouse-aware version.)

Eventually I found aquamacs, which only took a little customization to work the way my fingers expect. I now have Thunderbird hooked up with the External Editor extension so I can edit my outgoing email with emacs. I also use the same trick in the shell (EDITOR=/Applications/Aquamacs/Aquamacs\ Emacs.app/Contents/MacOS/bin/emacsclient) so svn prompts for check-in comments in emacs. It's quite handy.

Strohmi - Feb 5, 2008 7:00 am (#11 Total: 11)  

Reply to this message
 

Photo of Author
Posts: 1
Re: Emacs on the Mac

Hi hippert,

I tried hard to get the Aquamacs Emacs working with the External Editor Extension on Thunderbird, but I didn't find a solution.

Can you please help me and tell me how you get the Aquamacs working with Thunderbird.

Kind Regards Stefan



  OutlineAll MessagesOlder MessagesOldest MessagesNewest MessagesNewer Messages


 [F] TidBITS  / TidBITS  / TidBITS Talk  / Emacs on the Mac




Add a message

To add a message to this discussion, you must be a registered user. Enter your email address below. If you have an account associated with the email address you enter, you will be prompted for your password. If not, you'll be able to create a new account with no fuss.

Enter your email address:

Submit