Emacs Tips

Emacs as your IDE

You can get my emacs configuration files thus :

~$ tla register-archive jean-baptiste.note@m4x.org--libre-mirror http://jbnote.free.fr/{archives}/libre
~$ tla get jean-baptiste.note@m4x.org--libre-mirror/homedir--base

Emacs as mail reader

configuring gnus + bbdb

configuring gnus + gpg

http://www.zonix.de/div/el/gnus_gpg.html

Tagline

One feature I always have to painfully search the web for is syntax for the lines which force emacs in a given mode upon opening the file. It's

# --shell-script-- make emacs load this in shell-script mode

or

; --lisp-- make emacs load this in lisp-mode

Emacs-wiki

This site is published with Emacs-Wiki.

The markup is defined here :

Emacs Wiki markup

Some basic configuration info can be found here.

Sample more complex initialization script is emacs-wiki sample configuration.

Last but not least cool code for emacs-wiki.

I'd really like to find a cool CSS for this site. The default is not bad, though.

Emacs as your IDE

recursive edit

When replacing some text with M-% or M-C-% you may replace and edit the matches with C-w or just edit with C-r and leave recursive edit with M-C-c. This is usefull when you need to make replaces of some text, but in certain places it should differ.

stolen from

http://www.emacswiki.org/cgi-bin/emacs-en/ProgrammingEffectivelyWithEmacs

Indentation with emacs!

This site is full of tricks to better use emacs : Emacs as your IDE

And the FreeBSD doc : http://www.freebsd.org/doc/fr_FR.ISO8859-1/articles/programming-tools/emacs.html

And some other tricks : http://deesse.univ-lemans.fr/linuxcoding/download/dot_emacs

Yet another site with cool configuration tricks : config

And this really nice documentation, in French, about Emacs : emacs tutorial

From it, a nice tip :

C-h w (where-is)
Afficher les séquences de touches qui invoquent une commande dont on donne le nom. Plutôt utile.

Cscope is great too...

Index files
C-c s I
Find global definition
C-c s d
Find symbol definition
C-c s s
Find this file
C-c s f
Find functions calling this function
C-c s c
Find functions called by this function
C-c s C
Find this pattern
C-c s e
Find this text string
C-c s t
Find files including this file
C-c s i

In Hide-Show mode, use

Next line
C-M-n
Previous line
C-M-p
Next word
C-M-f
Previous word
C-M-b
Start of block
C-M-u
Indent block
C-M-q

Emacs misc

http://c2.com/cgi/wiki?GreatEmacsFeatures

C-u C-space
back in the position history (in one buffer)

-- find same thing that would work accross buffers.

Control-Meta-f
find closing brace
Control-Meta-b
find opening brace

Emacs music

in lilypond-mode,

C-x C-f
formats buffer for postscript
C-x C-p
view postscript output

in lilypond-quick-mode,

C-c o
change to / from relative mode

GNUS

http://mm.gnu.org.in/pipermail/fsf-friends/2004-April/001861.html