October 2000
Intermediate to advanced
1152 pages
26h 41m
English
Although Chapter 25 covers the basic syntax and language of shell programming, look at a few additional examples of scripts that are often useful in day-to-day operation.
Users who maintain source code, client lists, and other records often want to launch a find-and-replace operation from the command line. It's useful to have a variant of chstr on UNIX hosts. Listing 26.2 gives one example.
######## # # See usage() definition, below, for more details. # # This implementation doesn't do well with complicated escape # sequences. That has been no more than a minor problem in # the real world. # ######## usage() { echo \ "chstr BEFORE ... |
Read now
Unlock full access