On Fri, May 07, 2021 at 07:58:18AM -0700, John Hardin wrote: > On Sun, 2 May 2021, Loren Wilton wrote: > > > Now consider variable capture from the message: > > > > header __SUB_CAP Subject:Capture /Your (\w+) Order/i $(__COMPANY)=\1 > > I like this syntax. I was thinking that the capture would be implied - any > capturing group in a rule would automagically save its (single) match in a > variable named after the rule (kept separate from the rule's score) for > later use, but I like the explicit nature of this approach. > > Would :capture play well with (e.g.) :addr, :name, :raw, etc?
It might as well be a tflag or something. Why limit capturing to headers only? Or not a tflag at all. Just a uncommon enclosure format that is parsed from _any_ regex anywhere. All this is petty details compared to the overall logic that is required in the background.