James Sparenberg grabbed a keyboard and wrote:
>
> So the question is. Given an example old line:
>
> location of include ".:/var/www/html/php" # some inline comment.
>
> How would I add/insert
>
> :/var/www/html/newdir/php
>
> via script rather than VI (ok, or emacs)after php and before the " ?
There's probably a more elegant way of doing this, but:
cat php.ini | \
sed 's\:/var/www/html/php\:/var/www/html/php:/var/www/html/newdir/php\' | \
cat >php2.ini
should do it for you. You can then check the php2.ini file to make sure
everything is the way you want it, and then copy it back on top of the
original php.ini.
--Dave
--
David Guntner GEnie: Just say NO!
http://www.akaMail.com/pgpkey/davidg or key server
for PGP Public key
Want to buy your Pack or Services from MandrakeSoft?
Go to http://www.mandrakestore.com