On Tue, Sep 16, 2003 at 02:15:23PM -0600, np wrote:
> So I need to write a script which does a search and replace (ex.
> search for 'NEW', replace with 'In new condition, with no blemishes,"
> etc..)

#/bin/sed -f
#
# new2used -- replace "NEW" with appropriate string
#
s/NEW/In new condition, with no blemishes/g
# END SED SCRIPT

Call this with:

    scriptname < infile > outfile

Or, if you don't want to create a separate script:

    sed -e 's/NEW/In new condition, with no blemishes/' < infile > outfile

-- 
Chad Walstrom <chewie at wookimus.net>           http://www.wookimus.net/
           assert(expired(knowledge)); /* core dump */
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 240 bytes
Desc: not available
Url : http://shadowknight.real-time.com/pipermail/tclug-list/attachments/20030916/240a8aed/attachment.pgp