|
|
1.1 ! root 1: ! 2: # This shell will start a uucico for the system given. ! 3: # Options: ! 4: # -xN the debugging level for uucico (-x5 default) ! 5: # -r force the removal of the status file ! 6: # The output is put in /tmp/Name where Name is the name ! 7: # of the system name. A tail -f is performed after uucico is started. ! 8: ! 9: STATUS=/usr/spool/uucp/.Status ! 10: ! 11: if [ -x "./uucico" ]; then ! 12: UUCICO=./uucico ! 13: else ! 14: UUCICO=/usr/lib/uucp/uucico ! 15: fi ! 16: ! 17: REMOVE="" ! 18: X="-x5" ! 19: SYS= ! 20: while [ $# -gt 0 ] ! 21: do ! 22: case $1 in ! 23: -x) shift; X="-x$1"; shift;; ! 24: -x*) X=$1; shift;; ! 25: -r) REMOVE="y"; shift;; ! 26: *) SYS="$1"; shift;; ! 27: esac ! 28: done ! 29: ! 30: if [ -z "$SYS" ] ! 31: then ! 32: echo "$0: system name required" ! 33: exit 1 ! 34: fi ! 35: ! 36: # use 7 character maximum name length (SYSNSIZE in uucp.h) for search ! 37: SYSTEM=`echo $SYS | cut -c1-7` ! 38: ! 39: # check for existence in L.sys ! 40: # This is a bit complicated because one has to worry about ! 41: # names that may be prefixes of others! ! 42: XX= ! 43: XX=`uuname | grep $SYSTEM ` ! 44: if [ -z "$XX" ] ! 45: then ! 46: echo "Invalid system name \"$SYSTEM\"" ! 47: exit ! 48: fi ! 49: set $XX ! 50: FULLNAME=$1 ! 51: for i ! 52: do ! 53: if [ $i = $SYS ]; then ! 54: FULLNAME=$SYS ! 55: break ! 56: fi ! 57: done ! 58: ! 59: STMP=/tmp/$FULLNAME ! 60: rm -f $STMP ! 61: > $STMP ! 62: chmod 660 $STMP ! 63: # remove old status file ! 64: if [ -n "$REMOVE" ]; then ! 65: rm -f $STATUS/${FULLNAME} ! 66: fi ! 67: ! 68: echo "$UUCICO -r1 -s$FULLNAME $X >$STMP 2>&1&" ! 69: $UUCICO -r1 -s$FULLNAME $X >$STMP 2>&1& ! 70: ! 71: echo "tmp=$STMP" ! 72: tail -f $STMP
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.