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

Re: [PATCH 2/3] i18n: archive: mark errors for translation

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 9, 2016, 19:35 UTC
Message-ID
<xmqqvaz991m0.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<1470654961-2842-2-git-send-email-vascomalmeida@sapo.pt>
Vasco Almeida <vascomalmeida@sapo.pt> writes:
Show 28 quoted lines
> Signed-off-by: Vasco Almeida <vascomalmeida@sapo.pt>
> ---
>  archive.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/archive.c b/archive.c
> index 42df974..dde1ab4 100644
> --- a/archive.c
> +++ b/archive.c
> @@ -458,11 +458,11 @@ static int parse_archive_args(int argc, const char **argv,
>  	argc = parse_options(argc, argv, NULL, opts, archive_usage, 0);
>  
>  	if (remote)
> -		die("Unexpected option --remote");
> +		die(_("Unexpected option --remote"));
>  	if (exec)
> -		die("Option --exec can only be used together with --remote");
> +		die(_("Option --exec can only be used together with --remote"));
>  	if (output)
> -		die("Unexpected option --output");
> +		die(_("Unexpected option --output"));
> ...
> -		die("Unknown archive format '%s'", format);
> +		die(_("Unknown archive format '%s'"), format);
> ...
> -			die("Argument not supported for format '%s': -%d",
> +			die(_("Argument not supported for format '%s': -%d"),
>  					format, compression_level);

Hmm, this function is called by write_archive(), which can be called by the upload-archive process running on the remote end, whose locale certainly is different from that of your local environment.

If I do not read English and got one of these messages from the remote end, I can copy that into a search engine to read more about the error, but if I got it translated into, say, Portuguese, I'd have a (slightly) harder time dealing with the error, I would think.

Having said that, I expect that sites that expect internatinal audience to come would run these services in C locale, and other sites that target audiences in a single locale would choose to use their favourite single locale, so probably we do not have to worry about it.

Thanks.
Previous: Vasco AlmeidaNext: Vasco Almeida
Message 3 of 9 in “i18n: setup: mark error messages for translation”
  1. 1/3 i18n: setup: mark error messages for translationVasco Almeida, Aug 8, 2016
  2. 2/3 i18n: archive: mark errors for translationVasco Almeida, Aug 8, 2016
  3. Junio C HamanoAug 9, 2016
  4. Vasco AlmeidaAug 10, 2016
  5. 3/3 i18n: git-stash: mark message for translationVasco Almeida, Aug 8, 2016
  6. Junio C HamanoAug 9, 2016
  7. 1/3 i18n: setup: mark error messages for translationVasco Almeida, Aug 10, 2016
  8. 2/3 i18n: archive: mark errors for translationVasco Almeida, Aug 10, 2016
  9. 3/3 i18n: git-stash: mark messages for translationVasco Almeida, Aug 10, 2016

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.