[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how to call emacs from octave

From: John W. Eaton
Subject: Re: how to call emacs from octave
Date: Thu, 8 Mar 2007 16:48:06 -0500

On  8-Mar-2007, Jordi Gutierrez Hermoso wrote:

| On 08/03/07, sale kircanski <address@hidden> wrote:
| > BTW when I'm editing .m files within Emacs, my Emacs doesnt
| > recognize .m format and therefore does not color keywords
| > differently. How can I fix this?
| In Debian and all derivatives I know of,
|      aptitude install octave2.9-emacsen
| or
|      aptitude install octave2.1-emacsen ## or apt-get, if you will.
| should do the trick. These precise packages might not have trickled
| down to Ubuntu yet, but they should be there for Florid Fish or
| whatever it's called now.
| And if you're using a non-APT distro or if you don't have root
| privileges and can't be bothered to pester your sysadmin, I guess
| you'll have to download the Emacs octave-mode elisp files yourself,
| bytecompile them, and put them in the right directory for your Emacs
| to find them. They should come with instructions for this.

The Emacs mode for Octave is part of Emacs 21, so if you have Emacs 21
(or a more recent version) then you shouldn't have to install anything
and Emacs should recognize M-x octave-mode without having to do
anything special.

If you want Emacs to automatically recognize your .m files as Octave
files, then probably all you need to do is put

  ## -*- octave -*-

near the top of your .m files, or put

  ### Local Variables: ***
  ### mode: octave ***
  ### End: ***

near the bottom of your .m files, or add something like

  (setq auto-mode-alist (cons '("\\.m$" . octave-mode) auto-mode-alist))

to your ~/.emacs file.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]