Reputation: 2206
[Problem] When we look at changes, commit log is garbled.
as reported here. And I verified that the reason is just as hayarobi Park commented:
I'm running Jenkins on Windows 7 (Korean version, encoding is CP949) with msysgit-1.9.5-xxx. The git repository is on remote Linux machine. I have the issue that recent change message is corrupted.
After some testing and debugging git-plugin, I found, at least in my case, that the log message received from standard output of external git.exe was already corrupted. So, changelog.xml file in builds directory stores corrupted text.
git-client plugin execute external git.exe like this command, "git.exe whatchanged --no-abbrev -M --pretty=raw df1cca6135b7019dbd583693b59f6b97f408f5c5 ", and git.exe out change log to standard out. git-client plugin takes that output. In this point, the wrongfully converted message was received to git-client plugin.
The original message was UTF-8, but this message was assumed to current OS's encoding(CP949 in my computer) and then wrong encoding conversion (CP949 to UCS-2) is occured. I don't yet know which one is doing this wrong conversion; hudson Locallauncher, get.exe or other.
My verification process is as bellow:
So I try to solve the problem by config git log message encoding from default utf8 to gbk. What weird is that the the garbled chars still exists in Jenkins' change log page, although the changelog.xml file has been gbk encoded and can be viewed normally.
Then I'm at a lose for what do to next...
Upvotes: 1
Views: 1671
Reputation: 26
Try this on the cmd
git config --global i18n.commitEncoding cp949
git config --global i18n.logOutputEncoding cp949
Or change the encoding to whatever you need. It worked fine with me !
Upvotes: 1