Date: Sat, 07 Feb 2009 01:18:02 +0000 From: Adam Vande More <amvandemore@gmail.com> To: freebsd-questions@freebsd.org Subject: Re: insert new line in files Message-ID: <498CE14A.1090505@gmail.com> In-Reply-To: <498CCE9C.3060200@ibctech.ca> References: <498CBEBE.7080702@gmail.com> <20090206225619.GA75180@dan.emsphone.com> <498CC0FC.1040706@gmail.com> <20090206232129.GB75180@dan.emsphone.com> <498CCBA9.6010207@gmail.com> <498CCC94.6080507@gmail.com> <498CCE9C.3060200@ibctech.ca>
next in thread | previous in thread | raw e-mail | index | archive | help
Steve Bertrand wrote: > Adam Vande More wrote: > > >>> I also tried escaping ( ) . / to no avail. >>> >> nevermind I see I have to \\ that as well. Okay now I'm going to try to >> find a way to do this with find and xargs >> > > IMHO, this has become a job for Perl :) > > Steve > Thanks for help everyone. My final command was this: skynet1# find . -name 'filename.php' | xargs sed -i.old -e '37a\\ include("/usr/home/www/imp-sites/default_inventory.php");' I used double quotes because I couldn't finger out how to the single quote. Good enough for me.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?498CE14A.1090505>