Publishers of technology books, eBooks, and videos for creative people

Home > Articles

  • Print
  • + Share This
This chapter is from the book

Starting emacs and Dabbling with It

For the novice, emacs offers a reasonable middle ground between the user-friendliness of pico and the power of vi (or vim). It's not available on all systems, though, so you'll just have to type in the command to see if you have access to it. (Refer back to Chapter 1 if you don't.)

Using emacs, you can just type, as you'd expect, then use command sequences, which are basically ctrl.jpg keys, to make emacs do useful things like save, quit, and the like. When you start emacs, it'll probably look very much like Figure 4.17. Some systems "helpfully" open a new window and give you the graphical version; you'll see something like Figure 4.18.

Figure 4.17

Figure 4.17 emacs starts out with some basic information, but you can just start typing if you want.

Figure 4.18

Figure 4.18 emacs might helpfully start out in a spiffier interface if you're sitting at the keyboard of a Linux system. You can get the plain variety, though.

To start emacs:

  1. emacs

    At the shell prompt, type emacs. The program starts up and you'll see something like Figure 4.17. The helpful information may or may not be present, but you can ignore it for now at any rate.

  2. This morning I got up, went downstairs, and found a humongous spider in the bathroom. After I quietly composed myself, I looked around the house for something to put him in...the kids' bug catcher thing (nowhere to be found)...a jar... tupperware...a lidded cup...the salad spinner (BwaaaaHaaaHaaa!).... Type anything you want.

    You can use the arrow keys to navigate up and down in the file line by line. See Table 4.4 for a brief summary of the most useful commands in emacs.

    Table 4.4. Handy emacs Commands



    ctrl-x.jpg, ctrl-f.jpg

    Opens a new file (existing or new)


    Undoes the last change


    Cancels the current operation


    Bails out of menu selections (and other things)


    Moves down one page (screen)


    Moves up one page (screen)


    Moves to the beginning of the file


    Moves to the end of the file

  • + Share This
  • 🔖 Save To Your Account