git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: "Noralf Trønnes" <notro@tronnes.org>,
	"Torsten Bögershausen" <tboegi@web.de>,
	"Git Mailing List" <git@vger.kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>
Subject: Re: Git messes up 'ø' character
Date: Tue, 20 Jan 2015 16:20:49 -0500	[thread overview]
Message-ID: <20150120212049.GA22103@peff.net> (raw)
In-Reply-To: <CACBZZX58Di=m2YEKRuAsuU=bqUXjQhN21tvjRL8Z1Vbuyk2fKQ@mail.gmail.com>

On Tue, Jan 20, 2015 at 09:45:46PM +0100, Ævar Arnfjörð Bjarmason wrote:

> What's happened here is that:
> 
>  1. You've authored your commit in ISO-8859-1
>  2. Git itself has no place for the encoding of the author name in the
> commit object format

Is (2) right? The "encoding" header in a commit object should apply not
just to the commit message, but also to the author (and committer) name.

I think the real problem is simply that it defaults to UTF-8, but he is
giving it iso-8859-1 characters. Setting i18n.commitEncoding should fix
it.

-Peff

PS If you try experimenting with this, you may fall afoul of 08a94a1
   (commit/commit-tree: correct latin1 to utf-8, 2012-06-28), which will
   silently "correct" Latin1 characters into UTF-8 (when the commit
   message is expected to be in UTF-8, of course). So it actually
   _should_ just work under modern gits, but only for Latin1.

  parent reply	other threads:[~2015-01-20 21:20 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-20 19:46 Git messes up 'ø' character Noralf Trønnes
2015-01-20 20:07 ` Torsten Bögershausen
2015-01-20 20:17   ` Noralf Trønnes
2015-01-20 20:45     ` Ævar Arnfjörð Bjarmason
2015-01-20 21:05       ` Greg Kroah-Hartman
2015-01-20 21:20       ` Jeff King [this message]
2015-01-20 21:27         ` Ævar Arnfjörð Bjarmason
2015-01-20 21:23       ` Noralf Trønnes
2015-01-20 21:26         ` Ævar Arnfjörð Bjarmason
2015-01-20 21:38           ` Noralf Trønnes
2015-01-20 21:57             ` Ævar Arnfjörð Bjarmason
2015-01-20 22:18             ` Nico Williams
2015-01-20 22:26               ` Noralf Trønnes
2015-01-22  9:59                 ` Michael J Gruber

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=20150120212049.GA22103@peff.net \
    --to=peff@peff.net \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=notro@tronnes.org \
    --cc=tboegi@web.de \
    /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).