![]() |
|
In the UNIX world, the vi editor is ubiquitous. And since it has even been ported to DOS (and therefore is usable within Windows), it is one editor worth learning. Once you learn the basics, you usually find that many advanced commands are easily picked up because of the intuitive consistency of the editor's commands.
Learning the vi editor, by Linda Lamb, has been through six editions, which means that the book is successful enough for the publisher to keep printing, and that most of the errors and omissions have been eliminated. Possible reasons for the long life of this book may be its price, the continued popularity of UNIX, and ubiquity of the program. Another factor may be that Learning the vi editor is a book small enough that you can flick through it quickly as a desktop reference, yet it is large enough that even experienced UNIX programmers can find one or two obscure features covered. There is something Zen-like in this balance of not putting in too much or too little.
The first three chapters cover simple editing; enough for novices to become reasonably productive within a day. The remaining four chapters cover power features such as buffer manipulation, global search-and-replace, and the kind of advanced editing techniques you normally use a macro language for in other editors. As an aside, vi is interesting on several levels: the command language for vi is Turing-complete, which means it is as computationally expressive as traditional third-generation programming languages such as BASIC or PASCAL. Also, vi is usually implemented such that renaming it or accessing by a symbolic link under a different name changes its behavior: it interrogates argv[0] and acts accordingly. vi and ex, for instance, are the same program.
Learning the vi editor has four appendices: the first is a quick reference placed three quarters of the way through the book and requires a bookmark to find quickly; the second outlines rarely used environment settings; the third covers ex commands; and the final appendix is a simple problem check list.
-- Regan Russell
|
Explanation of ERCB rating scale:
|