ARTICLE

Book Review: Classic Shell Scripting
Contributed by Andy Kissner in Reviews on 2006-04-11 09:44:48

Classic Shell Scripting, in its own words, bridges the gap between Learning Unix (see: UNIX 101) and Unix in a Nutshell (throw a manual page at the reader; he'll be fine). It's aim is to provide a guide to writing scripts for the POSIX shell, which can be approached by novice and expert alike. Every tool that is introduced is accompanied by what looks like a condensed manual page, going over the major options and any peculiarities that the reader should know about. The book also has a chapter completely committed to awk, an underappreciated text processing language.

But what good is any of this without examples? Every chapter is bursting at the seams with them. Chapter 8 is comprised of nothing except for 2 examples summarizing everything learned so far, as is Chapter 11. Classic Shell Scripting has 15 Chapters and 3 Appendices, one of them devoted to the art of writing a manual page in roff markup. As has been my complaint with other O'REILLY books, there are a few typos, but only one or two were really detrimental to the text.

Since this was a book on shell-scripting, I was surprised to find an entire chapter devoted to awk. This special attention to awk was a bit of a double-edged sword. The chapter on awk was quite long, so the coverage was rather complete, however I thought that the space wasn't used efficiently. The examples on awk weren't thoroughly described, and some of the techniques used weren't completely explained elsewhere in the text. However, I feel that the coverage of awk was due, as it is used extensively in later examples in the book.

Another nice thing about the book were its three Appendices, Bibliography and Glossary, which accounted for about 20% of the book's content. This extra material supplemented the text very nicely, filling in some gaps that didn't really fit anywhere else. The bibliography was very complete, giving reference to some very informative sources beyond the scope of Classic Shell Scripting. The three appendices covered Manual Page writing, UNIX files, and a cheatsheet of common commands, respectively. I think that Appendix C ( the cheatsheet ) will prove an invaluable resource to those readers who are new to shell scripting ( or even UNIX in general). The history lesson on UNIX files was rather enlightening, as was the Manual Page guide.

In all, I thought that Classic Shell Scripting was a wonderful primer on the world of shell scripting. It should prove to be an invaluable tool for both shell newbies and UNIX veterans alike, if only for its abundance of real-world examples. And like all O'REILLY books, the sample code is made public for general consumption, so the useful additions to the UNIX toolbox can be easily integrated into any system. If they had just used their shell script from Chapter 12 on the book itself ( Chapter 12 covers spellchecking! ), this book would have scored a perfect five. But as it stands, I award Classic Shell Scripting 4 out of 5 penguins.


 
Discussion(s)
Scripting
Written by suresh on 2007-10-18 09:03:16
hi


how to write ip address in script
Discuss! Reply!

Shell Scripting
Written by Sivanageswararao on 2007-12-04 07:39:43
Hi,
How to write Shell Script.

Thanks,
Siva
Discuss! Reply!

shell
Written by ajay kumar d on 2008-01-31 06:51:51
Quote:

Hi,
How to write Shell Script.

Thanks,
Siva




by using loops, while & if statements .....!!
Discuss! Reply!