[PATCH 3 0/1] parse-options: localize mark-up of placeholder text in the short help
- From
Alexander Shopov <ash@kambanaria.org>
- Date
- Jul 7, 2024, 15:35 UTC
- Message-ID
- <20240707153526.97984-1-ash@kambanaria.org>
- In-Reply-To
- <xmqqttij86lc.fsf@gitster.g>
Hi Junio & Jiang,
I am submitting the patch taking into account the feedback you gave last time.
Just to quickly remind: this allows translatability of "<>" chars in:
OPT_STRING(0, "author", &force_author, N_("author"), N_("override author")),displayed as:
--[no-]author <author> override author
@Junio:
> ... above explanation ... should replace ... log message
Done
> The explanation after "such as:" needs improvement...
Improved and closely follows your suggestion
> user's language may use a convention different from ... [square brackets] > ... to mark an optional part ...
I decided againgst implementing this: - None of the translators have indicated such a need and adding it makes the whole thing more error prone - There is a tiny difference from what I did with the placeholder characters: I am actually skipping the characters in the Bulgarian translation (rather than substituting them) which leads to shorter but still clear messages. Skipping both "[]" and "<>" and will lead to confusion. "[]" are not as dangerous as "<>" for shell - If translators actually request it - it can be implemented when the real need arises
@Jiang
> ... with only one commit... not necessary to ... provide a cover letter
I agree but I am using the cover letter to remind what this is all about and point what I have done with the code revew. You can't remember all interactions.
> ... people don't like the markers ... "<" and ">" ... have special > meanings ... in shell programming
I have added something to this meaning in the log message.
Kind regards: al_shopov
Alexander Shopov (1): parse-options: localize mark-up of placeholder text in the short help
parse-options.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-)
-- 2.45.2