On Sat, 25 May 2002 the voices made Bart Schaefer write: > On Sat, 25 May 2002, Tony L. Svanstrom wrote: > > > Unless there's a "less is more"-thinking, I'd like to suggest: > > > > header ADVERT_CODE Subject =~ /\bADV(ert|erti\w*?)?:/i > > describe ADVERT_CODE Subject: contains advertising tag > > The colon at the end is supposed to be optional, right? And perhaps the > intent was not merly to match the word "advertisement" but to actually > require it to be either in brackets or followed by a colon.
Of course; looks like I messed up when I went from /\bADV:/i (which I personally think is a good enough improvement of the rule) to covering longer versions of adv... The more I look at it the more complex I find the problem to be, because when moving beyond "adv" we're getting too close to real, "innocent", words without common delimiters making them sure triggers. You'd prolly have to go with something like this "/(?:^\s*|[[({])ADV(?:ert(?:i\w*?)?)?[]:})]/i" > header ADVERT_CODE Subject =~ /\bADV(?:ert(?:i\w*?)?)?[]:]/i ^ I'm not sure I understand the purpose of the questionmark in "\w*?"; unless I'm missing something the greediness of "\w*" doesn't matter in this case??? > > Now please excuse me as I go find myself a life. > > You have a point. Esp. considering how much time I spent on that rule, and still messed up at the final step. =D (Looking at the current flow of spam I'd say that anything beyond /\bADV:/i is overkill today.) /Tony -- # Per scientiam ad libertatem! // Through knowledge towards freedom! # # Genom kunskap mot frihet! =*= (c) 1999-2002 [EMAIL PROTECTED] =*= # -- Random URL (2/8): <URL: http://www.apple.com/powerbook/ > *BSD, on the run, in style... _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ Spamassassin-talk mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/spamassassin-talk