#!/bin/sh # run-masses, Theo Van Dinter (c) 2002 # $Id: run-masses,v 1.18 2003/03/02 02:35:42 felicity Exp $ # Setup the path as necessary PATH=/bin:/usr/bin:/usr/local/bin:${HOME}/bin:. if [ -d /sw/bin ]; then PATH=${PATH}:/sw/bin fi export PATH # Use the specified directory for tests if [ -z "$1" ]; then DIR=../spamassassin-head else DIR="$1" shift fi # How many processes should we run at once? PROCS=`cpucount` # Where are our files located? MASS=$DIR/masses RULES=$DIR/rules # do the mass-check # class:format:path # class = ham | spam # format = file (file w/ single message) | mbox (file w/ multiple messsages) | dir (of 'file's) $MASS/mass-check --all -c $RULES -j $PROCS "$@" `mbox-to-check` echo "Generating hit frequency results" $MASS/hit-frequencies -c $RULES -x -p -a > results.log # remove the parse-rules-for-masses tmp directory echo "Removing temporary files" rm -rf ./tmp