* How to localize "git push"?
@ 2025-11-26 7:50 Peter Krefting
2025-11-27 23:05 ` brian m. carlson
0 siblings, 1 reply; 2+ messages in thread
From: Peter Krefting @ 2025-11-26 7:50 UTC (permalink / raw)
To: git
Hi!
Re: https://fosstodon.org/@McPringle/115611195011002487
The message shown when running "git push" without any changes queued is
always shown in English, whereas the corresponding message in "git pull"
is properly localized.
I looked at the sources, and the string "Everything up-to-date\n" is
included in both builtin/send-pack.c and transport.c, with both
instances annotated with a comment "stable plumbing output; do not
modify or localize".
How do we fix that? Having the message show in English from "git push"
is confusing. What is the corresponding plumbing command that needs to
have it machine-readable, so that we can fork that to fix "git push"?
--
\\// Peter - http://www.softwolves.pp.se/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: How to localize "git push"?
2025-11-26 7:50 How to localize "git push"? Peter Krefting
@ 2025-11-27 23:05 ` brian m. carlson
0 siblings, 0 replies; 2+ messages in thread
From: brian m. carlson @ 2025-11-27 23:05 UTC (permalink / raw)
To: Peter Krefting; +Cc: git
[-- Attachment #1: Type: text/plain, Size: 2220 bytes --]
On 2025-11-26 at 07:50:15, Peter Krefting wrote:
> Hi!
Hi,
> Re: https://fosstodon.org/@McPringle/115611195011002487
>
> The message shown when running "git push" without any changes queued is
> always shown in English, whereas the corresponding message in "git pull" is
> properly localized.
>
> I looked at the sources, and the string "Everything up-to-date\n" is
> included in both builtin/send-pack.c and transport.c, with both instances
> annotated with a comment "stable plumbing output; do not modify or
> localize".
>
> How do we fix that? Having the message show in English from "git push" is
> confusing. What is the corresponding plumbing command that needs to have it
> machine-readable, so that we can fork that to fix "git push"?
There isn't any tooling in Git that requires that particular message but
it's rather that other software outside of Git may depend on that
output.
It should be noted that "Everything up-to-date" should actually be
"Everything up to date", since it's an abbreviated form of "everything
is up to date" and for most compound adjectives, we only hyphenate them
in English before the noun they modify. However, because there was
supposedly existing software that expected that output, we chose not to
modify those messages at the time that cleanup went in. I am, however,
unable to find any such software that expects that string on GitHub with
a quick search.
Personally, I'm fine with modifying that message unless something like a
`--plumbing` argument is given (or just letting people set
`LC_ALL=C.UTF-8` if they want fixed output), but other people may not
be.
I will say that we changed the following message sometime back for
localization (to uppercase the N in "Needed") and it broke things at my
last company, but we also easily fixed it and I'm pleased that it's now
localized:
----
% git rev-parse --verify nonexistent
fatal: Needed a single revision
% LC_ALL=es_MX.UTF-8 git rev-parse --verify nonexistent
fatal: Se necesitó una revisión singular
% LC_ALL=fr_CA.UTF-8 git rev-parse --verify nonexistent
fatal : Une seule révision attendue
----
--
brian m. carlson (they/them)
Toronto, Ontario, CA
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 262 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-11-27 23:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-26 7:50 How to localize "git push"? Peter Krefting
2025-11-27 23:05 ` brian m. carlson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox