Emacs Basics

Xah Lee, 2005

If you are a programer, knowing emacs benefits you for life.

If you are running emacs in Microsoft Windows, just use your mouse and pull menus. The basics should be obvious, just like Microsoft's Notepad.

Download Emacs

emacs in OS X with GUI menu

above: Emacs in Mac OS showing the use of menu. Remember, real programers don't fear the mouse. Note that all keyboard shortcuts are shown beside the menu too.

emacs text menu

above: Emacs in a Text Terminal. In a text terminal, you can invoke the textual menu by pressing “Alt+`”. (or, pressing the Esc key followed by the backtick ` key.)

Emacs 1-Minute Tutorial: Open file, Edit, Save, Quit

The following are some emacs basics for operating emacs without the mouse. They are useful when you work in a text terminal and graphical menu is not available.

Start Emacs

Type: “emacs filename”, in your terminal.

Quit Emacs

Type: “Ctrl+x” then “Ctrl+c”. This means: holding down Contol key, press x, then holding down control key, press c.

Save

To save file, press “Ctrl+x” then “Ctrl+s”.

Quit without Saving

To quit without saving, just do quit and emacs will ask if you want to save.

Whenever confused in emacs where keystrokes doesn't seems to work, hold down Control then press g, which will cancel the sequence of keys you may have pressed by mistake.

Congratulations! You have obtained the Mastery of Emacs Basics!


Related essays:


Page created: 2005-10.
© 2005 by Xah Lee.
Xah Signet