more problems with commit encoding [Was: [PATCH] shortlog: respect commit encoding]
- From
Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
- Date
- Nov 24, 2009, 16:08 UTC
- Message-ID
- <20091124160837.GA7296@pengutronix.de>
- In-Reply-To
- <1259075555-7831-1-git-send-email-u.kleine-koenig@pengutronix.de>
Hello,
On Tue, Nov 24, 2009 at 04:12:35PM +0100, Uwe Kleine-König wrote:
> Before this change the author was taken from the raw commit without > reencoding.
while at it, userformats have the same problem:
linux-2.6$ for rev in b71a8eb bc9be01; do git show --format=%an $rev | head -n1; git show $rev | grep Auth; done Uwe Kleine-K�nig Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Uwe Kleine-König Author: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
That is, git show correctly reencodes its output for b71a8eb, but only without --format=...
(The patches above are in linux-next.)
And now take this (assuming locale and commitencoding are utf-8):
git init git config user.name 'Jöhännës Dschö' echo spam > ham git add ham git commit -m 'initial commit' git branch branch echo more spam > ham git add ham git commit -m "Commitlog matching '\nencoding:'
encoding: latin1 " git checkout branch echo much more spam > ham git add ham git commit -C master git show | grep Author:
Best regards Uwe
-- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ |