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

Re: Use of new .gitattributes working-tree-encoding attribute across different platform types

From
Jeff King <peff@peff.net>
Date
Jul 2, 2018, 18:20 UTC
Message-ID
<20180702182016.GB12208@sigill.intra.peff.net>
In-Reply-To
<4621C69D-B837-43ED-8570-462D4CF2BBA0@gmail.com>
On Mon, Jul 02, 2018 at 04:09:32PM +0200, Lars Schneider wrote:
Show 8 quoted lines
> Brian had a good argument [1] for an even more flexible system
> proposed by Peff:
> 
> 
> 1) We allow users to define custom encoding mappings in their Git config. 
> Example:
> 
>     git config --global core.encoding.myenc UTF-16

I think this should be encoding.myenc.something. In Git's config format, only the subsection names (the middle of a three-dot name) are unconstrained. So even if encoding.myenc only ever has one key ("replace" or "useInstead" or whatever you want to call it), there's value in organizing the namespace that way.

And as a bonus, it leaves room for extending the feature later if we do need more keys.

-Peff
Previous: Lars Schneider
Message 12 of 12 in “Use of new .gitattributes working-tree-encoding attribute across different platform types”
  1. Steve GroegerJun 27, 2018
  2. Torsten BögershausenJun 27, 2018
  3. brian m. carlsonJun 28, 2018
  4. Jeff KingJun 28, 2018
  5. Lars SchneiderJun 28, 2018
  6. Jeff KingJun 28, 2018
  7. brian m. carlsonJul 1, 2018
  8. Jeff KingJul 2, 2018
  9. Junio C HamanoJul 3, 2018
  10. Steve GroegerJul 2, 2018
  11. Lars SchneiderJul 2, 2018
  12. Jeff KingJul 2, 2018

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.