> Ive considered just deleting the entire file and using touch
> to recreate an empty mbox folder, but there must be a more elegant
> and safe way.
I'm sure there's better routes, but this is what I have for a daily
cron job - answer to the orig. question being "cp /dev/null foo"
[EMAIL PROTECTED]:/home/jmm% less bin/process_spam.sh
#!/bin/sh
PATH=/usr/bin:/bin
SPAM_MBOX=~/mail/spam
HAM_MBOX=~/mail/ham
if [ -s $SPAM_MBOX ]; then
sa-learn --spam --mbox $SPAM_MBOX
cp /dev/null $SPAM_MBOX
fi
if [ -s $HAM_MBOX ]; then
sa-learn --ham --mbox $HAM_MBOX
cp /dev/null $HAM_MBOX
fi
sa-learn --rebuild
--
James Manning <http://www.sublogic.com/james/>
GPG Key fingerprint = B913 2FBD 14A9 CE18 B2B7 9C8E A0BF B026 EEBB F6E4
--
TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug
TriLUG Organizational FAQ : http://trilug.org/faq/
TriLUG Member Services FAQ : http://members.trilug.org/services_faq/
TriLUG PGP Keyring : http://trilug.org/~chrish/trilug.asc