3 # Script to update Moira from Registrar's "tapes".
6 ##### date=`expr $date - 1` # files are postdated by 1 day
9 for who in staff student ; do
10 if [ -f tapes/$who.input.$date.Z ] ; then
12 && mv $who.input.0 $who.input.1 \
13 && mv $who.input $who.input.0
15 zcat tapes/$who.input.$date.Z | bin/$who.cvt > $who.input
18 && [ `diff $who.input.0 $who.input | wc -l` -lt 500 ] \
19 && bin/$who -n $who.input > $who.output.$date 2>&1 \
20 && egrep -v "($who): (adding|updating)" $who.output.$date > $who.err 2>&1 \
21 && cat /usr/local/lib/mail_header $who.err | mail dkk