All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Bucksch <ben.bucksch.news@beonex.com>
To: Michael J Gruber <git@drmicha.warpmail.net>
Cc: Jeremy White <jwhite@codeweavers.com>,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	"Boyd Stephen Smith Jr." <bss@iguanasuicide.net>,
	git@vger.kernel.org
Subject: Re: Thunderbird and patches (was Re: [PATCH v2] Enable setting attach as the default in .gitconfig   for git-format-patch.)
Date: Mon, 09 Feb 2009 17:24:20 +0100	[thread overview]
Message-ID: <499058B4.4070009@beonex.com> (raw)
In-Reply-To: <4990519C.8060601@drmicha.warpmail.net>

On 09.02.2009 16:54, Michael J Gruber wrote:
> I don't remember what else you need to quote within<pre></pre>.
>    

Escaping:

With mailto:, you send HTML (SGML) in a URL.

So, you first have to quote using HTML rules:
<   -> &lt;
 >   -> &gt;
&   -> &amp;
"   -> &quot;

If that's not done, TB/Mozilla may or may not fix it up: e.g. if you 
have html tags in your source code, it would probably go wrong without 
quoting.

After that, given that you put it in a URL, you need to escape it using 
"URL component rules" (same as you escape any URL GET parameter), using 
the %charcode rule, e.g.
(space)  ->   %20
=   ->   %3D
&   ->   %26
#   ->   %23
(Firefox does the URL escaping automatically when putting it in the 
URLbar, and you can also try it in JS using encodeURIComponent(), e.g. 
by opening the Firefox Error Console and writing 
encodeURIComponent("foo=bla&bar=baz bal"); or starting the 
yourfirefoxdir/js runner.)

E.g. "<" in original turns into "mailto:?html-body=<pre>%26lt;<pre>"

Sorry that it's non-trivial (I also hate escaping).

  reply	other threads:[~2009-02-09 16:26 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-08  3:26 [PATCH v2] Enable setting attach as the default in .gitconfig for git-format-patch Jeremy White
2009-02-08  5:10 ` Boyd Stephen Smith Jr.
2009-02-08 16:01   ` Jeremy White
2009-02-08 17:28     ` Johannes Schindelin
2009-02-09 12:34       ` Michael J Gruber
2009-02-09 13:25         ` Ben Bucksch
2009-02-09 13:36           ` Johannes Schindelin
2009-02-09 13:50             ` Michael J Gruber
2009-02-09 14:39               ` Boyd Stephen Smith Jr.
2009-02-09 13:52             ` Ben Bucksch
2009-02-09 14:49               ` Johannes Schindelin
2009-02-09 13:52             ` Thunderbird and patches (was Re: [PATCH v2] Enable setting attach as the default in .gitconfig for git-format-patch.) Jeremy White
2009-02-09 14:18               ` Ben Bucksch
2009-02-09 15:38                 ` Jeremy White
2009-02-09 15:54                   ` Michael J Gruber
2009-02-09 16:24                     ` Ben Bucksch [this message]
2009-02-09 18:06                       ` Jeremy White
2009-02-09 18:54                       ` Brandon Casey
2009-02-09 19:09                         ` Ben Bucksch
2009-02-09 19:14                           ` Johannes Schindelin
2009-02-09 19:20                             ` Ben Bucksch
2009-02-09 19:30                               ` Brandon Casey
2009-02-09 19:51                                 ` Ben Bucksch
2009-02-09 19:59                                   ` Ben Bucksch
2009-02-09 21:03                                     ` Brandon Casey
2009-02-09 21:07                                       ` Brandon Casey
2009-02-09 22:01                                       ` Ben Bucksch
2009-02-09 22:13                                         ` Brandon Casey
2009-02-09 22:25                                           ` Ben Bucksch
2009-02-09 22:28                                             ` Brandon Casey
2009-02-09 22:46                                               ` Ben Bucksch
2009-02-10  1:00                                                 ` Brandon Casey
2009-02-09 19:33                             ` Brandon Casey
2009-02-09 20:09                               ` Johannes Schindelin
2009-02-10 10:07                                 ` Michael J Gruber
2009-02-12  4:37                                   ` Thunderbird and patches Miles Bader
2009-02-12 10:07                                     ` Michael J Gruber
2009-02-09 19:22                           ` Thunderbird and patches (was Re: [PATCH v2] Enable setting attach as the default in .gitconfig for git-format-patch.) Brandon Casey
2009-02-09 19:00                       ` [PATCH] example patch corrupted by thunderbird Brandon Casey
2009-02-09 15:49                 ` Thunderbird and patches (was Re: [PATCH v2] Enable setting attach as the default in .gitconfig for git-format-patch.) Michael J Gruber
2009-02-09 22:39               ` Thunderbird and patches Ben Bucksch
2009-02-09 22:55                 ` Jeremy White
2009-02-09 23:01                   ` Ben Bucksch
2009-02-10  1:41 ` [PATCH v2] Enable setting attach as the default in .gitconfig for git-format-patch Junio C Hamano

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=499058B4.4070009@beonex.com \
    --to=ben.bucksch.news@beonex.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=bss@iguanasuicide.net \
    --cc=git@drmicha.warpmail.net \
    --cc=git@vger.kernel.org \
    --cc=jwhite@codeweavers.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.