git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "ZHANG, Le" <r0bertz@gentoo.org>
To: git@vger.kernel.org
Cc: "ZHANG, Le" <r0bertz@gentoo.org>
Subject: [PATCH v4 0/4] add --recode-patch parameter to mailinfo and am
Date: Mon, 29 Nov 2010 03:10:13 +0800	[thread overview]
Message-ID: <1290971417-4474-1-git-send-email-r0bertz@gentoo.org> (raw)

I have a translation project which uses UTF-8 as charset.
So the patch must be encoded in UTF-8, not just the commit msg etc.
And we use google group as our mailing list.

Recently, mails saved from gmail are encoded using local charset if all the
characters in the patch are in that specific local charset even if the orignal
mail is in UTF-8. This seems smart but it caused inconvenience for
our project.

Since we have no control on what google will do, so I took another way,
i.e. add this option to git-mailinfo. I hope this could benefit others as
well.

Changelog:

v4 -> v3:
* Added a target_charset parameter to convert_to_utf8() in mailinfo.c.
* Introduced a new config varible: i18n.patchencoding, which will be used solely
  by --recode-patch parameter.

v2 -> v3:
* Removed 'const' type qualifier from handle_patch()'s parameter
* Fixed typos in commit msg

v1 -> v2:
* Clarified how -u/--encoding is handled in git-mailinfo's documentation


ZHANG, Le (4):
  mailinfo.c: convert_to_utf8(): added a target_charset parameter
  i18n.patchencoding: introduce a new config variable
  git mailinfo: added a --recode-patch parameter
  git am: added a --recode-patch parameter

 Documentation/git-am.txt       |    4 ++++
 Documentation/git-mailinfo.txt |    6 +++++-
 builtin/mailinfo.c             |   27 +++++++++++++++++----------
 cache.h                        |    1 +
 config.c                       |    3 +++
 environment.c                  |    1 +
 git-am.sh                      |   13 +++++++++++--
 7 files changed, 42 insertions(+), 13 deletions(-)

-- 
1.7.3.2.344.gb3680.dirty

             reply	other threads:[~2010-11-28 19:10 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-28 19:10 ZHANG, Le [this message]
2010-11-28 19:10 ` [PATCH v4 1/4] mailinfo.c: convert_to_utf8(): added a target_charset parameter ZHANG, Le
2010-11-29 20:23   ` Junio C Hamano
2011-04-16  6:22     ` ZHANG, Le
2010-11-28 19:10 ` [PATCH v4 2/4] i18n.patchencoding: introduce a new config variable ZHANG, Le
2010-11-29 20:23   ` Junio C Hamano
2010-11-28 19:10 ` [PATCH v4 3/4] git mailinfo: added a --recode-patch parameter ZHANG, Le
2010-11-29 20:23   ` Junio C Hamano
2010-11-28 19:10 ` [PATCH v4 4/4] git am: " ZHANG, Le

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=1290971417-4474-1-git-send-email-r0bertz@gentoo.org \
    --to=r0bertz@gentoo.org \
    --cc=git@vger.kernel.org \
    /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).