Author: Keith Evans
Date: 15:22:58 09/13/01
Go up one level in this thread
On September 13, 2001 at 16:03:21, Slater Wold wrote: >Cleaning somethings up, and wondered if anyone here knew how to add lines using >sed in Linux. > >I search, find, replace, and then I want to add 2 or 3 lines of text at the >bottom of that file. > >Any help will be appreciated. > > >PS Of course I looked everywhere I knew to look. But I know someone on here >will know. :) Why not just do the following after running sed: echo 'some text' >> filename echo 'some more text' >> filename Change the quote characters depending upon your needs. Put your sed script and whatever else you need into a shell script (I personally prefer to use /bin/sh) and you should be set. You could look into Awk or Perl, but I'm assuming that you don't want to do that for this problem. If you have access to O'Reilly's "Unix Power Tools" they probably have some nice well documented examples in there. -Keith
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.