From: Junio C Hamano Date: Sun, 06 Jun 2010 20:03:04 GMT Subject: Re: [PATCH 1/2] [RFC] add --recode-patch option to git-mailinfo Message-ID: <7vr5kkvshz.fsf@alter.siamese.dyndns.org> In-Reply-To: <1275825583-23913-1-git-send-email-r0bertz@gentoo.org> Zhang Le writes: > 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, due to unknown reason, mails saved from gmail are encoded using GB2312. > This never happened before. I guess google has did something. > But I haven't found how to change this behavior. > > So I took another way, i.e. add this option to git-mailinfo. > I hope this could benefit others as well. > > Signed-off-by: Zhang Le > --- > builtin/mailinfo.c | 8 +++++++- > man1/git-mailinfo.1 | 7 ++++++- Don't patch anything in man?/ as they are autogenerated files and not source; patch the source file in Documentation/ directory instead. I take it that you recode from whatever encoding the mail message is in (probably stated in "Content-type: ...; charset=xxx" header) to the encoding specified with --encoding option (defaulting to UTF-8), but it wasn't very clear from the documentation. We might want to improve the descriptions of both this new option and --encoding option. Also it might be useful to find out what that "due to unknown reason" is, at least to see if that is what Google did or what the user did. Thanks.