brothers and sisters in perl ,
I hope that I am not the first to encounter difficulty with spam-assassin's sa-learn.

It seems while spamc and spamd have options for sql stored bayes_dbs or virtual user directories, sa-learn has a completly different syntax for specifying configuration and user_prefs locations. Having seen posts on the sa-talk mailing list regarding this collect zero responses, I decided to have a bash getting sa-learn to use virtual config directories in the manner of spamd.

After browsing the source for a minute, making this hack to CmdLearn.pm allowed me to use the option username and virtual-config-dir , combining them to pass user_dir to Mail::Spamassassin::new. With SA 2.53, Mail::SpamAssassin::CmdLearn

56,59d55 < 'virtual-config-dir|v=s' => \$opt{'virtual-co +nfig-dir'}, < 'username|u=s' => \$opt{'username'} +, < < 91d86 < user_dir => join ( '/' , $opt{'virtual-config-dir'} , $ +opt{'username'} ),
Has anyone else come across this while using spam assassin, no users have system accounts on the server I am configuring. More to the point, has anybody made this work already?

thanks
-toaster

I can't believe it's not psellchecked

In reply to Mail::SpamAssassin::CmdLearn hacking by submersible_toaster

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.