Emacs
Emacs is a powerful editor available on all the CBIF systems. Its primary use is for editing the contents of files, but in addition it can perform a host of other valuable tasks. Thus, it is a valuable tool to understand. This guide provides a brief introduction to using Emacs and, more importantly, links to additional information and tutorials that will improve your ability to make effective use of this important tool.
Introduction
Emacs is a powerful editor available on all the CBIF systems. Its primary use is for editing the contents of files, not controlling the typeface used to visualize the information (although it can do that also). In addition, however, it can perform a host of valuable tasks beyond editing files.
- Editing many distinct files simultaneously
- Comparing the contents of files with each other
- Reading, sending, and managing email
- Compiling and interactively debugging programs
- Executing UNIX shell commands
- ... and much more.
Because manipulating the contents of files plays such an important role in computing, knowledge of an editor is crucial. Because of its power and broad availability, emacs is an editor worth learning. Because of its power, however, it is unlikely that you will become a master with it anytime soon. However, your effort spent learning it will be rewarded with increased productivity.
Running emacs
Emacs may be started in one of two basic ways, either from the command line or from the KDE menus on the CBIF workstations. When started from the command line it may be run either in a simple textual mode, which is especially suitable for slow network links, or in a full graphical mode, which enables control via mouse events. The following commands illustrate how to start emacs in these two different modes. Note that the pound signs (#) and the text following them are comments elaborating on the two commands and are not actually part of them.
emacs -nw # start emacs in text mode, i.e., with no windoes (-nw)
emacs & # start emacs in the background (&), allowing graphical control
In order to start emacs from the KDE menus select K -> Editors -> Emacs. Even better, add an emacs icon to the KDE task bar.
Note that in order to start emacs so that it is editing a specific file (even one that does not yet exist), the above commands would be modified as follows, where the word "filename" just stands for whatever name the actual file has.
emacs -nw filename
emacs filename &
Resources
The following resources provide further information on emacs.