From: Karl Kleinpaste <karl@charcoal.com>
Subject: Re: Eliminating repetitious "Re: Re: Re: ..."
Date: 31 Jan 2001 14:57:52 -0500 [thread overview]
Message-ID: <vxkd7d3lcjj.fsf@cinnamon.vanillaknot.com> (raw)
In-Reply-To: <5bzog761e2.fsf@avocet.cs.rochester.edu> (ShengHuo ZHU's message of "31 Jan 2001 13:07:49 -0500")
[-- Attachment #1: Type: text/plain, Size: 322 bytes --]
ShengHuo ZHU <zsh@cs.rochester.edu> writes:
> What if the header is
> Subject: [foo] Re: [foo] Re: [foo] Re: the original subject
Then the identifiers should be removed one at a time.
Below is a new patch (from original source) which loops until no more
identifiers are present, and then eliminates excess "Re: ".
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: updated nnmail Re: patch --]
[-- Type: text/x-patch, Size: 856 bytes --]
--- lisp/nnmail.el.~1~ Tue Jan 23 09:12:11 2001
+++ lisp/nnmail.el Wed Jan 31 14:09:26 2001
@@ -1096,10 +1096,14 @@
(mapconcat 'identity nnmail-list-identifiers " *\\|"))))
(when regexp
(goto-char (point-min))
- (when (re-search-forward
- (concat "^Subject: +\\(Re: +\\)?\\(" regexp " *\\)")
- nil t)
- (delete-region (match-beginning 2) (match-end 0))))))
+ (while (re-search-forward
+ (concat "^Subject: +\\(R[Ee]: +\\)*\\(" regexp " *\\)")
+ nil t)
+ (delete-region (match-beginning 2) (match-end 0))
+ (beginning-of-line))
+ (when (re-search-forward "^Subject: +\\(\\(R[Ee]: +\\)+\\)R[Ee]: +" nil t)
+ (delete-region (match-beginning 1) (match-end 1))
+ (beginning-of-line)))))
(defun nnmail-remove-tabs ()
"Translate TAB characters into SPACE characters."
next prev parent reply other threads:[~2001-01-31 19:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-01-31 14:31 Karl Kleinpaste
2001-01-31 15:41 ` Oyvind Moll
2001-01-31 18:07 ` ShengHuo ZHU
2001-01-31 19:57 ` Karl Kleinpaste [this message]
2001-01-31 20:55 ` ShengHuo ZHU
2001-02-02 21:22 ` Paul Jarc
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=vxkd7d3lcjj.fsf@cinnamon.vanillaknot.com \
--to=karl@charcoal.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).