#ident "@(#)samples/bigsite/bargw/news/cron.daily 1.2 10/24/90 05:20:37" # The commands in this file should be executed from cron once per day, # probably in the wee hours of the morning when nothing is going on. LOGNAME=netnews LIB=/usr/local/lib/news smail=/usr/lib/smail editor=netnews # unbatch new map articles and make new maps (cd $smail; make -s) # show errors, if any if [ -s $smail/maps/world.err ] then cat $smail/maps/world.err fi # show differences, if any diff $smail/maps/O.world.path $smail/maps/world.path # send errors to editor, and accumulate a weekly batch if [ -s $LIB/errlog ] then cp $LIB/errlog $LIB/errlog.tmp && : > $LIB/errlog cat $LIB/errlog.tmp >> $LIB/errlog.week mailx -s "inews errors" $editor < $LIB/errlog.tmp && rm -f $LIB/errlog.tmp fi exit 0