[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: example script want



|"> awk '{ print }
|"> /section\[xyz\]/ { print "new line of text"; }'
|"
|"Your version will print "new line of text" every time "section[xyz]" is
|"matched anywhere in the input line. The form I gave ensures that only an
|"exact match for the whole line does this.

Yes, a small oversight; it should have read:

/^section\[xyz\]$/ { print "new line of text"; }'

instead.

Ronald van Loon (ronald@and.nl)

"I am waiting as fast as I can! I want patience, and I want it *NOW*!"
                                                     - Bethany J. Parkhurst


Reply to: