{"thread":{"id":"7793","subject":"[BUG] git gui and my ö","startedAt":"2007-04-23T11:32:25Z","lastAt":"2007-04-24T08:57:15Z","messageCount":4,"participants":["Uwe Kleine-König","Shawn O. Pearce"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"40194","messageId":"20070423113225.GA5427@lala","threadId":"7793","inReplyTo":null,"subject":"[BUG] git gui and my ö","fromName":"Uwe Kleine-König","fromEmail":"ukleinek@informatik.uni-freiburg.de","sentAt":"2007-04-23T11:32:25Z","receivedAt":"2007-04-23T11:32:25Z","isPatch":false,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hello,\n\nwhen I try to amend a commit with git gui that is properly signed-off by\nme and hit \"Commit\", I get \n\n\tcommit-tree failed:\n\n\t<sha1 sum>\n\tWarning: commit message does not conform to UTF-8.\n\tYou may ...\n\nThe commit was done with git-commit, I have \n\n\tzeisberg@cassiopeia:~$ set | grep -E '^L(ANG|C_)'\n\tLANG=en_US.UTF-8\n\tLC_CTYPE=en_US.UTF-8\n\nand the ö is properly displayed in the commit message text box before\nhitting Commit.  When I remove the ö, I can commit (and re-amend on the\ncmdline).\n\nI'm using:\n\n\tzeisberg@cassiopeia:~/gsrc/linux-2.6$ git version\n\tgit version 1.5.1.1.190.g74474\n\tzeisberg@cassiopeia:~/gsrc/linux-2.6$ git gui version\n\tgit-gui version 0.6.5.10.g845d3\n\nI don't know tcl/tk very well, so for now you only get a report and no\npatch :-(\n\nBest regards\nUwe\n\n-- \nUwe Kleine-König\n\nhttp://www.google.com/search?q=5%2B7\n"},{"id":"40289","messageId":"20070424053935.GO17480@spearce.org","threadId":"7793","inReplyTo":"20070423113225.GA5427@lala","subject":"Re: [BUG] git gui and my ö","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2007-04-24T05:39:35Z","receivedAt":"2007-04-24T05:39:35Z","isPatch":false,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Uwe Kleine-K??nig <ukleinek@informatik.uni-freiburg.de> wrote:\n> \tcommit-tree failed:\n> \n> \t<sha1 sum>\n> \tWarning: commit message does not conform to UTF-8.\n> \tYou may ...\n> \n> The commit was done with git-commit, I have \n> \n> \tzeisberg@cassiopeia:~$ set | grep -E '^L(ANG|C_)'\n> \tLANG=en_US.UTF-8\n> \tLC_CTYPE=en_US.UTF-8\n\nWhat does your git-config think is the value of i18n.commitencoding?\nIf its unset git-gui assumes utf-8 as the encoding.  Hmm...\n\nThis particular code is around line 1287 of git-gui:\n\n   1287     # -- Build the message.\n   1288     #\n   1289     set msg_p [gitdir COMMIT_EDITMSG]\n   1290     set msg_wt [open $msg_p w]\n   1291     if {[catch {set enc $repo_config(i18n.commitencoding)}]} {\n   1292         set enc utf-8\n   1293     }\n   1294     fconfigure $msg_wt -encoding $enc -translation binary\n   1295     puts -nonewline $msg_wt $msg\n   1296     close $msg_wt\n\nWe should be writing the commit message (here $msg) out to a\ntemporary file ($msg_p / $msg_t), using a UTF-8 encoding ($enc).\nApparently that's not what's happening here.  I wonder if the Tk\ntext widget is feeding me UTF-8, and the way I have configured the\nfile channel Tcl is than mangling things futher... *sigh*\n\nAnyone reading this a better Tcl guru than I?\n\n\nI'll try to take a look at this tomorrow.  I'll have to figure out\nhow to get your proper name into git-gui first.  :-)\n\nI had thought I had most of git-gui i8n safe, but apparently not.\nThanks for the bug report!\n\n-- \nShawn.\n"},{"id":"40293","messageId":"20070424061652.GP17480@spearce.org","threadId":"7793","inReplyTo":"20070424053935.GO17480@spearce.org","subject":"Re: [BUG] git gui and my ö","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2007-04-24T06:16:52Z","receivedAt":"2007-04-24T06:16:52Z","isPatch":false,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"\"Shawn O. Pearce\" <spearce@spearce.org> wrote:\n> Uwe Kleine-K??nig <ukleinek@informatik.uni-freiburg.de> wrote:\n> > \tcommit-tree failed:\n> > \tWarning: commit message does not conform to UTF-8.\n\nThis was starting to bug me, so I went off and found it.  OK, well\nthe encoding error anyway.  git-gui incorrectly claimed commit-tree\nfailed when it didn't.  But besides the point, this is the bad line:\n\n>    1294     fconfigure $msg_wt -encoding $enc -translation binary\n\nI have had trouble in the past with trying to use that magic\n-encoding flag on fconfigure to get Tcl's file channels to perform\nencoding work for me.  Seems it doesn't work right or something...\nso other parts of git-gui (e.g. the filename handling parts)\nperform the convertfrom/convertto logic on their own... but the\ncommit message handling parts didn't.\n\nThey do now (git gui 0.6.5-11-gf20db5f).\n\nCan you please test my current master branch and see if that fixes\nthings for you?  repo.or.cz, git-gui.git...\n\nIf it does, I'm probably going to tag that as 0.6.6 and let Junio\ncut 1.5.2 with that release.\n\n-- \nShawn.\n"},{"id":"40309","messageId":"20070424085715.GA9334@informatik.uni-freiburg.de","threadId":"7793","inReplyTo":"20070424061652.GP17480@spearce.org","subject":"Re: [BUG] git gui and my ö","fromName":"Uwe Kleine-König","fromEmail":"ukleinek@informatik.uni-freiburg.de","sentAt":"2007-04-24T08:57:15Z","receivedAt":"2007-04-24T08:57:15Z","isPatch":false,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hello Shawn,\n\nShawn O. Pearce wrote:\n> \"Shawn O. Pearce\" <spearce@spearce.org> wrote:\n> > Uwe Kleine-K??nig <ukleinek@informatik.uni-freiburg.de> wrote:\n> > > \tcommit-tree failed:\n> > > \tWarning: commit message does not conform to UTF-8.\n> \n> This was starting to bug me, so I went off and found it.  OK, well\n> the encoding error anyway.  git-gui incorrectly claimed commit-tree\n> failed when it didn't.  But besides the point, this is the bad line:\n> \n> >    1294     fconfigure $msg_wt -encoding $enc -translation binary\n> \n> I have had trouble in the past with trying to use that magic\n> -encoding flag on fconfigure to get Tcl's file channels to perform\n> encoding work for me.  Seems it doesn't work right or something...\n> so other parts of git-gui (e.g. the filename handling parts)\n> perform the convertfrom/convertto logic on their own... but the\n> commit message handling parts didn't.\n> \n> They do now (git gui 0.6.5-11-gf20db5f).\n> \n> Can you please test my current master branch and see if that fixes\n> things for you?  repo.or.cz, git-gui.git...\nWorks fine.  I pulled in your changes[1] and it worked with one test\ncase.  (I amended the merge and added a sign-off. ;-)\n\nBest regards and thanks\nUwe\n\n[1] Thanks to gitster in #git to explain how to do it.  It's as easy as:\n\n\tgit pull -s subtree git://.../git-gui.git master\n\n-- \nUwe Kleine-König\n\nhttp://www.google.com/search?q=gravity+on+earth%3D\n"}]}