From: Junio C Hamano <gitster@pobox.com>
To: Konstantin Khomoutov <kostix@bswap.ru>
Cc: git@vger.kernel.org, Kazuhiro Kato <kazuhiro.kato@hotmail.co.jp>
Subject: Re: [PATCH 1/2] Fixing file name encoding issues.
Date: Wed, 19 Feb 2025 10:02:05 -0800 [thread overview]
Message-ID: <xmqqmsehg6ea.fsf@gitster.g> (raw)
In-Reply-To: <20250219173032.x5gzw6hsvsu4flba@carbon> (Konstantin Khomoutov's message of "Wed, 19 Feb 2025 20:30:32 +0300")
Konstantin Khomoutov <kostix@bswap.ru> writes:
> On Tue, Feb 18, 2025 at 10:42:25PM +0000, Kazuhiro Kato via GitGitGadget wrote:
>
> [...]
>> diff --git a/gitk-git/gitk b/gitk-git/gitk
>> index 47a7c1d29c4..88951ed2384 100755
>> --- a/gitk-git/gitk
>> +++ b/gitk-git/gitk
>> @@ -12379,6 +12379,7 @@ catch {
>> if {$gitencoding == ""} {
>> set gitencoding "utf-8"
>> }
>> +encoding system utf-8
>> set tclencoding [tcl_encoding $gitencoding]
>> if {$tclencoding == {}} {
>> puts stderr "Warning: encoding $gitencoding is not supported by Tcl/Tk"
>
> I'm not sure one should sensibly do this - except to implement some
> well-understood and well-documented kludge, simply because the "system
> encoding" is supposed to be set by the Tcl runtime.
> ...
> In other words, your patch (supposedly) works on UTF-8-based systems
> which is common to Linux-based OSes and MacOS, but I'm afraid it won't work on
> Windows.
In other words, things should work without "encoding system blah"
forcing a particular encoding that Tcl may not agree with? Would
this mean perhaps in a "curious" repository with paths encoded in
something Tcl does not expect to be used (e.g., on a UTF-8 system
somehow EUC-jp is used for paths containing Japanese characters), it
needs to be possible to specify a "curious" encoding either with an
end-user on-demand action (e.g., menu items) or with an repository
configuration (e.g., gitk.pathencoding = euc-jp)?
Thanks.
next prev parent reply other threads:[~2025-02-19 18:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-18 22:42 [PATCH 0/2] gitk: Fixing file name encoding issues Kazuhiro Kato via GitGitGadget
2025-02-18 22:42 ` [PATCH 1/2] " Kazuhiro Kato via GitGitGadget
2025-02-19 17:30 ` Konstantin Khomoutov
2025-02-19 18:02 ` Junio C Hamano [this message]
2025-02-18 22:42 ` [PATCH 2/2] fix: when resolving merge conflicts, japanese file names become garbled Kazuhiro Kato via GitGitGadget
2025-02-19 18:11 ` Junio C Hamano
2025-02-18 22:52 ` [PATCH 0/2] gitk: Fixing file name encoding issues Junio C Hamano
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=xmqqmsehg6ea.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=kazuhiro.kato@hotmail.co.jp \
--cc=kostix@bswap.ru \
/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).