Implement two kinds of filtering in Edwin's simple news reader:
filtering out messages that match criteria, such as spam; and
filtering headers of kept messages.
See the documentation strings for the new Edwin variables
NEWS-HEADER-FILTER and NEWS-KEPT-HEADERS. New procedures
NEWS-HEADER-SPLITTING-FILTER and NEWS-HEADER-REGEXP-FILTER are useful
for constructing the value of NEWS-HEADER-FILTER. For example,
I have this in my .edwin, so that any messages with xref headers
whose values contain `gmane.spam.detected' on any Gmane news servers
will be ignored:
(add-event-receiver! (ref-variable news-group-mode-hook)
(let ((gmane-spam-filter
(news-header-regexp-filter
'(("xref" . ".*gmane\\.spam\\.detected.*")))))
(lambda (buffer)
(if (string-prefix? "gmane." (buffer-name buffer))
(local-set-variable! news-header-filter
gmane-spam-filter
buffer)))))