>Thanks for the proposed localpostproc, Ken!
>looping mechanism -- or, at least, a "there-exists" mechanism.
>I need something that checks the recipients' host(s), which
>means potentially checking more than 1 string. The pseudo-code
>would be roughly
>
> if @.*stanford.edu in {%(host{to}), %(host{cc}), %(host{bcc})}
> postflags=""
> else
> postflags="-server smtp.gmail.com -port submission -tls -sasl -user
> dnc2dnc"
I think you're overthinking it. I used %(host), because I wanted to extract
out something that would be in a case statement, but you have the entire
power of the shell; you could easily do something like this:
if scan -format '%{to} %{cc} %{bcc} %{dcc}' "$draftname" | grep -iqs
@stanford.edu; then
... set for stanford ...
else
... set for everything else ...
fi
Well, you might want to change that grep, but you get the idea. I know,
the issue with things like %(host) only working on one address is a pain;
I am unsure how to solve that.
--Ken
_______________________________________________
Nmh-workers mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/nmh-workers