[kw-pm] Specifying editing environment in source file itself
Rolando Blanco
rblanco at texadasoftware.com
Fri Nov 22 15:51:16 CST 2002
As I mentioned yesterday in the meeting, there's a way to specify, in a
source file, what editing environment should be used when editing the
file. From the emacs manual:
"A file can specify local variable values for use when you edit the
file with Emacs. Visiting the file checks for local variables
specifications; it automatically makes these variables local to the
buffer, and sets them to the values specified in the file."
To set the editing variables, the first or second line of the file must
contain the variable specifications within '-*-' and '-*-'. Example:
#!/usr/local/bin/perl
# -*- mode: cperl; tab-width: 4; indent-tabs-mode: nil -*-
This will make emacs display all tabs in the file with width 4.
...Rolando
More information about the kw-pm
mailing list