Subject: Re: [PATCH v2 1/1] diff: mark param1 and param2 as placeholders

From: Junio C Hamano <[email-masked]>
Date: Wed, 14 Feb 2024 09:33:03 -0800

Jiang Xin <[email-masked]> writes:

> Some l10n translators translated the parameters "files", "param1" and
> "param2" in the following message:
>
>     "synonym for --dirstat=files,param1,param2..."
>
> Translating "param1" and "param2" is OK, but changing the parameter
> "files" is wrong. The parameters that are not meant to be used verbatim
> should be marked as placeholders, but the verbatim parameter not marked
> as a placeholder should be left as is.
>
> This change is a complement for commit 51e846e673 (doc: enforce
> placeholders in documentation, 2023-12-25).
>
> With the help of Jean-Noël,some parameter combinations in one
> placeholder (e.g. "<param1,param2>...") are splited into seperate
> placeholders.
>
> Helped-by: Jean-Noël Avila <[email-masked]>
> Signed-off-by: Jiang Xin <[email-masked]>
> ---
>  diff.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Makes sense, thanks both.  This is from 2019 so it is not all that
urgent, but it still is a good change.

It is a bit unfortunate that we need to mark what *can* be
translated, not the other way around.  Because of that, something
like ...

>  			       N_("synonym for --dirstat=cumulative"),

... has no marking, but that does not mean that any part of
"--dirstat=cumulative" is up for translation, while "synonym for"
definitely is to be translated.

> +		OPT_CALLBACK_F(0, "dirstat-by-file", options, N_("<param1>,<param2>..."),
> +			       N_("synonym for --dirstat=files,<param1>,<param2>..."),