On Thu, Jan 31, 2008 at 07:23:19PM +0000, Martin Gregorie wrote:
> I need to scan a set of archived mbox files for spam, mark the messages
> appropriately, and save them in a second mbox file. Should the following
> command do what I want?
> 
> spamassassin --mbox <mbox >scanned.mbox

Yes, though you can skip the input redirection.

spamassassin --mbox input.mbox > scanned.mbox

> I'm currently running spamc/spamd and know that works strictly one
> message at a time, but don't understand the ins and outs of using SA to
> process bulk files. I've read through the man pages and online
> documentation but didn't see an explicit answer to this question.
> Apologies for wasting bandwidth if I should have seen it.  

I'm biased of course, but I think it's pretty obvious from the man page:

$ man spamassassin-run
[...]
       By default, message(s) are read in from STDIN (< mailmessage),
       or from specified files and directories (path ...)  STDIN and
       files are assumed to be in file format, with a single message
       per file.  Directories are assumed to be in a format where each
       file in the directory contains only one message (directories are
       not recursed and filenames containing whitespace or beginning with
       "." or "," are skipped).  The options --mbox and --mbx can override
       the assumed format, see the appropriate OPTION information below.
[...]
       --mbox
           Specify that the input message(s) are in mbox format.
           mbox is a standard Unix message folder format.
[...]


-- 
Randomly Selected Tagline:
"Have we had the chance to play with a blow torch Nikki?" - Mr. Wizard

Attachment: pgp9BY58lLkuH.pgp
Description: PGP signature

Reply via email to