Error "commit message does not conform to utf-8" from git gui only

1,027 views
Skip to first unread message

jiho

unread,
Apr 7, 2010, 12:26:32 PM4/7/10
to msysGit
Hi,

I have installed the latest msysgit on a computer with windows Vista
and I am having plenty of encoding problems (which seems common). To
put things in context, the problems were:

1- git bash could not open because the name of the home directory had
an accent it it: C:\Users\Propriétaire
I set git's HOME explicitely in etc/profile to something else (C:
\Program Files\Git\home) and it worked

2- git commit or stash, from the command line would give me the
"commit message does not conform to utf-8" error. Setting user.name
and user.email fixed it. My guess is that git was fetching so defaults
from the system which were problematic. Setting them (to values with
only ASCII characters) fixed it.

And now:

3- git commit works form the command line but committing from git gui
still gives "commit message does not conform to utf-8", even when the
commit message contains only ASCII characters. I tried setting
i18n.commitecoding to UTF-8 explicitly but that did not help. I read
there were encoding issues with gitk in general.

Does anyone have a clue at the solution? A workaround? It seems that
changing the home directory name to something without accent may help
but really don't know the consequences (or wether it is even
possible). I am setting this up for a student. I use OSX and Linux
myself.

Thanks in advance.

Konstantin Khomoutov

unread,
Apr 7, 2010, 1:19:29 PM4/7/10
to msysGit
On 7 апр, 20:26, jiho <jo.iris...@gmail.com> wrote:

[...]


> 2- git commit or stash, from the command line would give me the
> "commit message does not conform to utf-8" error. Setting user.name
> and user.email fixed it. My guess is that git was fetching so defaults
> from the system which were problematic. Setting them (to values with
> only ASCII characters) fixed it.

Did your commit reach a text editor? Or you have used the "-m" command-
line option to `git commit`?

> 3- git commit works form the command line but committing from git gui
> still gives "commit message does not conform to utf-8", even when the
> commit message contains only ASCII characters. I tried setting
> i18n.commitecoding to UTF-8 explicitly but that did not help. I read
> there were encoding issues with gitk in general.

I failed to reproduce it.
I created a test repository, set the user.name local config parameter
to "Jean Propriétaire", added a file, fired git gui, entered a commit
message in Russian and committed the change -- all went OK.
After that I verified that `git log` outputs correct UTF-8, which it
did -- with accented character in the user's name and cyrillic
characters in the commit message.
gitk also had no problems displaying these fields in the commit log.

I'm using Windows XP, but nevertheless it looks like a problem with
your Git install. Could you may be try test the same actions using an
"ASCII-clean" user account?

Reply all
Reply to author
Forward
0 new messages