From: Junio C Hamano <gitster@pobox.com>
To: Jiang Xin <worldhello.net@gmail.com>
Cc: Jean-Noel Avila <jn.avila@free.fr>, Git List <git@vger.kernel.org>
Subject: Re: [PATCH] Add hint for translators for y/n reply.
Date: Sat, 28 Feb 2015 20:02:00 -0800 [thread overview]
Message-ID: <xmqqa8zxgybr.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <CANYiYbGuRjNZARc278py=MzDDXukAfLJv3kWdnBa6_ia7WDvRg@mail.gmail.com> (Jiang Xin's message of "Sun, 1 Mar 2015 08:18:48 +0800")
Jiang Xin <worldhello.net@gmail.com> writes:
> 2015-02-28 23:39 GMT+08:00 Jean-Noel Avila <jn.avila@free.fr>:
>> Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
>> ---
>> builtin/clean.c | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/builtin/clean.c b/builtin/clean.c
>> index 7e7fdcf..2c98661 100644
>> --- a/builtin/clean.c
>> +++ b/builtin/clean.c
>> @@ -754,6 +754,9 @@ static int ask_each_cmd(void)
>> /* Ctrl-D should stop removing files */
>> if (!eof) {
>> qname = quote_path_relative(item->string, NULL, &buf);
>> + /*TRANSLATORS: Make sure to include [Y] and [n] in your
>> + translation. The program will only accept English input
>> + at this point. */
A comment "We will accept only y, Y, Ye, YE,... as 'affirmative'" in
the code to translators will not help the end users at all, so make
it a single liner like this:
/* TRANSLATORS: make sure to keep [y/N] as-is */
Make sure you have SP after slash-asterisk.
>> printf(_("remove %s? "), qname);
>
> Yes, it may confuse. In order to let the translators notice this and update,
> you'd better change the code like this:
>
> printf(_("remove %s [y/N]? "), qname);
A very good suggestion. The code that follows this part treats an
empty input and a random non-empty input that does not head-match
"yes" as "please do not remove"; upcasing N is a good visual hint
that that "no" is the default.
Thanks.
next prev parent reply other threads:[~2015-03-01 4:02 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20150212085211.9112780692@smtp-out.fingerprint.fr>
2015-02-23 15:46 ` Internationalization and yes/no prompts Pierre-Olivier Vares
2015-02-24 20:32 ` Junio C Hamano
2015-02-25 9:42 ` Jean-Noël Avila
2015-02-28 15:39 ` [PATCH] Add hint for translators for y/n reply Jean-Noel Avila
2015-03-01 0:18 ` Jiang Xin
2015-03-01 0:30 ` Jiang Xin
2015-03-01 4:02 ` Junio C Hamano [this message]
2015-03-01 11:58 ` [PATCHv2] Add hint interactive cleaning Jean-Noel Avila
2015-03-02 19:39 ` 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=xmqqa8zxgybr.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=jn.avila@free.fr \
--cc=worldhello.net@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.