From: Jeff King <peff@peff.net>
To: Lars Schneider <larsxschneider@gmail.com>
Cc: "brian m. carlson" <sandals@crustytoothpaste.net>,
Steve Groeger <GROEGES@uk.ibm.com>,
git@vger.kernel.org
Subject: Re: Use of new .gitattributes working-tree-encoding attribute across different platform types
Date: Thu, 28 Jun 2018 13:27:07 -0400 [thread overview]
Message-ID: <20180628172707.GA31766@sigill.intra.peff.net> (raw)
In-Reply-To: <4E8CDDC9-2957-401F-9BBE-93276C026848@gmail.com>
On Thu, Jun 28, 2018 at 07:21:18PM +0200, Lars Schneider wrote:
> How about this:
>
> 1) We allow users to set the encoding "auto". Example:
>
> *.txt working-tree-encoding=auto
>
> 2) We define a new variable `core.autoencoding`. By default the value is
> UTF-8 (== no re-encoding) but user can set to any value in their Git config.
> Example:
>
> git config --global core.autoencoding UTF-16
>
> All files marked with the value "auto" will use the encoding defined in
> `core.autoencoding`.
>
> Would that work?
Yeah, that was along the lines that I was thinking. I wonder if anybody
would ever need two such auto-encodings, though. Probably not. But
another way to think about it would be to allow something like:
working-tree-encoding=foo
and then in your config "foo" to map to some encoding.
But that may be over-engineering, I dunno. utf8 has always been enough
for me. :)
-Peff
next prev parent reply other threads:[~2018-06-28 17:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-27 7:54 Use of new .gitattributes working-tree-encoding attribute across different platform types Steve Groeger
2018-06-27 17:38 ` Torsten Bögershausen
2018-06-28 2:44 ` brian m. carlson
2018-06-28 14:34 ` Jeff King
2018-06-28 17:21 ` Lars Schneider
2018-06-28 17:27 ` Jeff King [this message]
2018-07-01 17:56 ` brian m. carlson
2018-07-02 18:17 ` Jeff King
2018-07-03 16:01 ` Junio C Hamano
2018-07-02 12:13 ` Steve Groeger
2018-07-02 14:09 ` Lars Schneider
2018-07-02 18:20 ` Jeff King
-- strict thread matches above, loose matches on Subject: below --
2018-06-27 7:50 Steve Groeger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180628172707.GA31766@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=GROEGES@uk.ibm.com \
--cc=git@vger.kernel.org \
--cc=larsxschneider@gmail.com \
--cc=sandals@crustytoothpaste.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).