From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
Subject: [sup-talk] [PATCH] New hook to allow formatting of message headers
Date: Thu, 06 Dec 2007 18:12:09 +0100 [thread overview]
Message-ID: <1196960854-sup-7925@192.117.33.51.static.012.net.il> (raw)
In-Reply-To: <1196879746-sup-2883@south>
Excerpts from William Morgan's message of Wed Dec 05 19:36:44 +0100 2007:
> Excerpts from William Morgan's message of Wed Dec 05 10:12:16 -0800 2007:
> > I've applied this to SVN trunk, but (as I am wont to do) I tweaked it a
> > bit.
>
> Tweaked it a little more to use an OrderedHash and to just modify the
> headers in place. This way the header ordering is not random.
>
> Here's the new hook:
>
> $ cat detailed-headers.rb
> %w(User-Agent X-Mailer X-Spam-Status).map do |key|
Why use .map instead of .each the result seems not that useful.
> if message.raw_header =~ /^#{key}: (.*)$/i
> headers[key] = $1
> end
> end
>
--
Nicolas Pouillard aka Ertai
WARNING: multiple messages have this Message-ID
From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
Subject: [sup-talk] [PATCH] New hook to allow formatting of message headers
Date: Thu, 06 Dec 2007 18:14:52 +0100 [thread overview]
Message-ID: <1196960854-sup-7925@192.117.33.51.static.012.net.il> (raw)
Message-ID: <20071206171452.otf7p7kvdbE3axpqo_yho1ZB3wYYU9Fou-Yc1N5YcRg@z> (raw)
In-Reply-To: <1196879746-sup-2883@south>
Excerpts from William Morgan's message of Wed Dec 05 19:36:44 +0100 2007:
> Excerpts from William Morgan's message of Wed Dec 05 10:12:16 -0800 2007:
> > I've applied this to SVN trunk, but (as I am wont to do) I tweaked it a
> > bit.
>
> Tweaked it a little more to use an OrderedHash and to just modify the
> headers in place. This way the header ordering is not random.
>
> Here's the new hook:
>
> $ cat detailed-headers.rb
> %w(User-Agent X-Mailer X-Spam-Status).map do |key|
Why use .map instead of .each the result seems not that useful.
> if message.raw_header =~ /^#{key}: (.*)$/i
> headers[key] = $1
> end
> end
>
--
Nicolas Pouillard aka Ertai
next prev parent reply other threads:[~2007-12-06 17:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-21 4:26 Colin Bell
2007-12-05 18:12 ` William Morgan
2007-12-05 18:36 ` William Morgan
2007-12-06 17:12 ` Nicolas Pouillard [this message]
2007-12-06 17:14 ` Nicolas Pouillard
2007-12-07 18:10 ` William Morgan
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=1196960854-sup-7925@192.117.33.51.static.012.net.il \
--to=nicolas.pouillard@gmail.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