git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Update l10n guide

From
Jiang Xin <worldhello.net@gmail.com>
Date
Mar 2, 2012, 12:18 UTC
Message-ID
<CANYiYbG-Gp0cELF7_CxT1veRod+ookBaucfjCpWZjK1kTC0sAQ@mail.gmail.com>
In-Reply-To
<4F50A55E.8040705@viscovery.net>
2012/3/2 Johannes Sixt <j.sixt@viscovery.net>:
Show 7 quoted lines
> It does not convert, but it records which encoding the text has. If you
> don't specify anything, UTF-8 is assumed, and if your text is actually not
> UTF-8, the result is necessarily garbage.
>
> Then you haven't set i18n.commitEncoding. Try this:
>
>   git config i18n.commitEncoding CP936

I know there are two config variables. i18n.commitEncoding will insert a "encoding XX" line to the commit object, while i18n.logOutputEncoding will set the default output encoding. But this implementation seems like a workaround.

* Tree objects do not have such implementation, so multibyte characters
   can not be used as filenames.
* Commit object without "encoding" instruction will be used as it is. So
  people under the same non-utf8 locale may not notice that they
  have not set the proper i18n.commitEncoding, until one day they
  need accross platform development.
* As raw commit log alway used as fallback, sometimes it is hard to find
  commit objects with wrong encoding instructions.

I think save commit object, tree object, packed-refs in UTF-8 is a better implementation.

-- 
Jiang Xin
Previous: Johannes SixtNext: Jakub Narebski
Message 8 of 11 in “l10n: the maintaince of git-po repo”
  1. Jiang XinFeb 28, 2012
  2. Junio C HamanoFeb 29, 2012
  3. Update l10n guideJunio C Hamano, Feb 29, 2012
  4. Jiang XinMar 1, 2012
  5. Junio C HamanoMar 1, 2012
  6. Jiang XinMar 2, 2012
  7. Johannes SixtMar 2, 2012
  8. Jiang XinMar 2, 2012
  9. Jakub NarebskiMar 2, 2012
  10. Junio C HamanoMar 2, 2012
  11. Update l10n guide: change the repository URL, etcJiang Xin, Mar 2, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.