in reply to `hostname -s`
$HOSTNAME = `hostname -s`;
$HOSTNAME includes "\n". Chomp it.
Update: Here's a way to see what's happening:
prompt$ perl -e '$HOSTNAME = `hostname -s`; print $HOSTNAME;' | od -c
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: `hostname -s`
by joeymac (Acolyte) on Nov 28, 2011 at 20:12 UTC |
In Section
Seekers of Perl Wisdom