On Wed, 2005-02-16 at 07:50 -0500, Aaron Walker wrote:
> Also keep in mind that Linux is not the only operating system Gentoo runs on
> nowadays.  hostname on Linux is not the same as hostname on BSD (which by
> default prints the fully qualified hostname not the short hostname).  I 
> believe
> using 'hostname -s' should produce the same output on both operating systems.

On Solaris it is simply `hostname'.

if [ "$(uname -s)" == "SunOS" ]; then
  foo="$(hostname)"
else
  foo="$(hostname -f)"
fi


-- 
Regards,
Lisa Seelye
GPG: 09CF5 2D6B8 2B72B 997A7 601BC B46B5 561E4 96FC5
http://www.thedoh.com/~lisa/site

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to