Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can you change the commnad emacs startup the standard Emacs?

I run emacs and get XEmacs as an editor in an external window. I would like to get the default Emacs inside Ubuntu's terminal.

which emacs gives me /usr/bin/emacs which seems to be the normal Emacs. I could of course make an alias for emacs. However, I see that this is not the right solution, since other apps may not then see the alias, but use the setting which makes XEmacs my default Emacs.

share|improve this question
up vote 2 down vote accepted

In a terminal,

sudo update-alternatives -–config emacs

and choose emacs there

share|improve this answer
This works for debian based distributives :) – vava Aug 26 '09 at 11:29
Use the -nw option to make Emacs use the console instead of opening its own window. – Lars Haugseth Aug 26 '09 at 13:17
@Masi, hm, try --config emacsclient. I've just tried this myself and xemacs also don't want to become alternative to emacs on my computer. But then again, 'emacs' starts emacs, not xemacs here. – vava Aug 27 '09 at 1:46
@Masi, take a look at /etc/alternatives, see if there are any emacs like links that points to xemacs. If there isn't any, then your problem is somewhere else. If there is, update-alternative --config link-name will help you. – vava Aug 27 '09 at 1:57
@Lars, sudo update-alternatives --config emacs22 and chose normal emacs there, not gtk version would do the same but in Ubuntu way. – vava Aug 27 '09 at 2:06

You must log in to answer this question.

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