I'm using RH 5.0, and I have a dial-up connection to the Net. When I dial
in, I run a script containing these lines, to update my /etc/hosts:
if [ -a /var/run/ppp0.pid ]; then
IP=`ifconfig | grep P-t-P | cut -c 23-34`
cat /etc/hosts-up | sed -e s/--IP--/$IP/g > /etc/hosts
fi
If I execute the second and third lines, one at a time, from the command
line myself, they work perfectly. But if I run them in a script (like I'm
trying to do) sed keeps complaining:
sed: Unterminated `s' command
I'm sort of new to Linux and unix in general, but I know enough to get
around. What's going on here?
James Curbo
[EMAIL PROTECTED]
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com/RedHat-FAQ /RedHat-Errata /RedHat-Tips /mailing-lists
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject.