home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Fred Fish Collection 1.5
/
ffcollection-1-5-1992-11.iso
/
ff_disks
/
300-399
/
ff319.lzh
/
CNewsSrc
/
cnews.orig.lzh
/
misc
/
newshostname
< prev
next >
Wrap
Text File
|
1989-06-27
|
575b
|
15 lines
#! /bin/sh
# newshostname - print the hostname known to the news system
# =()<. ${NEWSCONFIG-@<NEWSCONFIG>@}>()=
. ${NEWSCONFIG-/usr/lib/news/bin/config}
# export NEWSCTL NEWSBIN NEWSARTS
PATH=$NEWSCTL/bin:$NEWSBIN:$NEWSPATH ; export PATH
umask $NEWSUMASK
# "test -r && cat" is used here instead of just "cat" because pre-v8
# cat's are broken and return good status when they can't read their files.
( (test -r $NEWSCTL/whoami && cat $NEWSCTL/whoami) || hostname ||
(test -r /etc/whoami && cat /etc/whoami) ||
uuname -l || uname -n || echo the_unknown_host) 2>/dev/null