home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Usenet 1994 January
/
usenetsourcesnewsgroupsinfomagicjanuary1994.iso
/
sources
/
misc
/
volume32
/
xbbs
/
part09
/
sysop
< prev
next >
Wrap
Text File
|
1992-09-08
|
2KB
|
71 lines
:
#sysop
# This script will assist the sysop in performing his chores in
# administrating the XBBS.
# Copyright April 23, 1987 Dighera Data Services
#
ORGDIR=/usr/sandy/bbs # Directory where the XBBS log files reside
HOMDIR=/usr/bbs # Home Directory of bbs account w/.configbbs
echo "\014"
cat << EOT
Enter Your Choice --
B. Login to BBS
1. Who's on port 1A?
2. Who's on port 2A?
A. Last Questionnaire Answer
T. Toggle user monitoring (1A or 2A)
S. Grant user Sysop-access for this session
C. Chat with user (tty1A or tty2A)
D. Dump user (1A or 2A)
E. Edit the userpriv.bbs file to alter users privleges
P. Pack the message files
U. Allign the Users file (Delimits each record in users.bbs with NL)
F. Fix users (Converts old 4 charcter passwords to new format)
Q. Quit to UNIX
?
EOT
read CHOICE
case $CHOICE in
[bB]*) DIR=`pwd`; export DIR;cd $HOMDIR; su bbs; cd $DIR;;
[12]*) if echo $CHOICE | grep '^1'; then CHOICE=1;else CHOICE=2; fi;
finger | awk '(NR == 1 || /^bbs/) {print}'; echo;
tail $ORGDIR/callers.bbs${CHOICE}A;;
[aA]*) ls -l $ORGDIR/answer.bbs && (echo; tail -21 $ORGDIR/answer.bbs);;
[uU]*) $ORGDIR/allign/allign;;
[fF]*) echo "Not yet implemented";;
[tT]*) who | awk '/^bbs/ {print}'; echo "\nWhich port (1A or 2A)? \c";
read CHOICE; export CHOICE;
su bbs -c "kill -16 `cat /tmp/pid$CHOICE` && echo 'BBS user on port '$CHOICE' successfully toggled.'";;
[sS]*) who | awk '/^bbs/ {print}'; echo "\nWhich port? \c";read CHOICE;
case $CHOICE in
*1A) PID=`head /tmp/pid1A`; kill -17 $PID;;
*2A) PID=`head /tmp/pid2A`; kill -17 $PID;;
*) echo "\nNo such port";;
esac;;
[cC]*) who | awk '/^bbs/ {print}'; echo "\nWhich port? \c";read CHOICE;
case $CHOICE in
*1A) chatbbs tty1A;;
*2A) chatbbs tty2A;;
*) echo "\nNo such port";;
esac;;
[dD]*) echo "\n\nWhich port? (1A or 2A) \c"; read CHOICE;
if test $CHOICE = ""; then exec $0; fi;
# su bbs -c "stty 0 </dev/tty${CHOICE} || echo \nError dumping user on tty${CHOICE}";;
su bbs -c "kill -9 `cat /tmp/pid${CHOICE}`";;
[eE]*) vi userpriv.bbs;;
[pP]*) $ORGDIR/msgpack/msgpack;;
[qQ]*) echo "\014"; exit;;
*) exec $0;;
esac
echo "\n Enter to Continue ... \c"
read PAUSE
exec $0