;; Mail sent to `mdw-nospam-THING' should appear to come from this address.
(setq gnus-posting-styles
- '(((and (string-match "^nnimap\\+distorted:crap\\.\\(.*\\)$"
- gnus-newsgroup-name)
- (setq mdw-from-address
- (replace-match "mdw-nospam-\\1@distorted.org.uk"
- nil nil gnus-newsgroup-name)))
- ("From" mdw-from-address))))
+ '(("^nnimap\\+distorted:crap\\."
+ (address (concat "mdw-nospam-"
+ (substring gnus-newsgroup-name (match-end 0))
+ "@distorted.org.uk")))))
;; The actual splitting rules.
(setq nnmail-split-fancy