Richard Riley <[email protected]> writes:
> David <[email protected]> writes:
>> Richard Riley <[email protected]> writes:
>>> I was wondering if anyone has a solution for setting the
>>> gnus-posting-style address based on a "email-from" field or similar on a
>>> contacts bbdb record?
>>
>> Put the following function in your .gnus:
>
> Hi David,
>
> I got it going. Great. I did have to define my own symbol though e.g
>
> (setq email-type (make-symbol "email-type"))

I don't understand why this would be necessary. What kind of error do
you get when you omit this? 

You have to create the field in the BBDB, of course.

> I understand that the first clause ",(rx.." produces a match string
> (regexp) which is later evaluated against the group name. The second
> searches for the email-type field and matches it is type "dev".
>
> But how could I combine them so as not to have to repeat the other
> forms?

You could try something like (untested)

(setq gnus-posting-styles
      '(
        ((or (string-match (rx (or "DevelopmentEmail" "emacs" ))
                            gnus-newsgroup-name)
             (DE-bbdb-match-field-recipient 'email-type "GWDG"))
          (name "Richard Riley")
          (address "[email protected]")
          (from "Richard Riley <[email protected]>"))))

-David



_______________________________________________
info-gnus-english mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/info-gnus-english

Reply via email to