Node:Default Configuration, Next:Site-wide Init, Previous:Emacs Initialization, Up:Emacs Initialization
There are those who appreciate Emacs' default configuration. After all, Emacs starts you in C mode when you edit a C file, starts you in Fortran mode when you edit a Fortran file, and starts you in Fundamental mode when you edit an unadorned file. This all makes sense, if you do not know who is going to use Emacs. Who knows what a person hopes to do with an unadorned file? Fundamental mode is the right default for such a file, just as C mode is the right default for editing C code. But when you do know who is going to use Emacs--you, yourself--then it makes sense to customize Emacs.
For example, I seldom want Fundamental mode when I edit an otherwise undistinguished file; I want Text mode. This is why I customize Emacs: so it suits me.
You can customize and extend Emacs by writing or adapting a
~/.emacs file. This is your personal initialization file; its
contents, written in Emacs Lisp, tell Emacs what to do.1
~/.emacs file contains Emacs Lisp code. You can write this
code yourself; or you can use Emacs'
customize feature to write
the code for you. You can combine your own expressions and
auto-written Customize expressions in your
(I myself prefer to write my own expressions, except for those,
particularly fonts, that I find easier to manipulate using the
customize command. I combine the two methods.)
Most of this chapter is about writing expressions yourself. It
describes a simple
.emacs file; for more information, see
Init File, and
may also add
~/.emacs and call it a
~/.emacs.el file. In the past, you were forbidden to type the
extra keystrokes that the name
~/.emacs.el requires, but now
you may. The new format is consistent with the Emacs Lisp file
naming conventions; the old format saves typing.