Making Emacs Work the Way You Want
If you’ve been reading straight through this book, you may have started a list of things to do each time you start Emacs, such as
Turn on auto-fill mode so Emacs does word wrap.
If you have X, turn on transient mark mode so that Emacs highlights selected text.
If you have flow-control problems (where C-s freezes your session), solve them permanently.
We’re going to tell you how to give Emacs the to-do list, a list of options to turn on each time you enter Emacs. These options are defined in an initialization file called .emacs. Initialization files run automatically. Some, like .login, run when you start a UNIX session. Others, like .emacs, run when you start up an associated software program. So .emacs runs automatically when you start Emacs and turns on whatever options the file defines. Emacs doesn’t need this file to run; its only purpose is to make Emacs work the way you want it to.
Throughout this book, we will give you lines of text that you can, if you wish, add to your .emacs file. When you want to add a line to your .emacs file, take these steps:
Enter Emacs (if you’re not already there).
Type C-x C-f ~/.emacs and press RETURN.
Press ESC > to move to the end of the file.
Type the line to be added exactly as shown in this book. 
Press C-x C-s to save the .emacs file.
Press C-x C-c to exit Emacs.
Type emacs to restart Emacs and have the line take effect.
If you make a minor typing mistake (such as forgetting a quotation mark or a parenthesis), ...