# DSSS (Scan Manager tool) Copyright (C) 2004 Nicolas Riesz. # # This program is free software; you can redistribute it and/or modify it under the terms of the GNU General # Public License as published by the Free Software Foundation; either version 2 of the License, or (at # you option) any later version. # ** are items that you may need to adjust # ** change this to your home HOME=/home/cacou # ** change the following to where you want your log files to be LOG=$HOME/sd/log LOGDSSS=$HOME/sd/logdsss LOGERR=$HOME/sd/logerr PAT=$HOME/sd/pattern_options if [ "$1" == "--help" ] then echo "Usage: sh nget_cron [--test | --help]." exit 0 else if [ "$1" == "--test" ] then TEST=-T fi fi exec 2>$LOGERR cd $HOME/sd # build pattern-options file cut -sf 1 rules | sed 's/^\([^,]*\)/-R $subject \\\"\1\\\" == /g' | sed 's/,\([^,]*\)/subject \\\"\1\\\" == \&\& /g' | sed 's/$/$/g' | tr "$" "\"" > $PAT cat $PAT > $LOG # retrieve files (use -T to test) # ** you may have to change the path /usr/local/bin/nget $TEST -p us -g comics -@ $PAT >> $LOG # save size of downloaded files du -hc us/*.jpg us/*.JPG &>1 | grep "total$" >> $LOG # run simi ./dsss.pl cron > $LOGDSSS