git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [L10N] Kickoff of translation for Git 2.10.0 round 1
@ 2016-08-15 15:04 Jiang Xin
  2016-08-20 16:01 ` Jean-Noël AVILA
  0 siblings, 1 reply; 15+ messages in thread
From: Jiang Xin @ 2016-08-15 15:04 UTC (permalink / raw)
  To: Alexander Shopov, Alex Henrie, Ralf Thielow, Jean-Noël Avila,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Jiang Xin,
	Nelson Martell, Brian Gesiak
  Cc: Junio C Hamano, Git List

Hi,

Git v2.10.0-rc0 has been released, and it's time to start new round of git l10n.
This time there are 248 updated messages need to be translated since last
update:

    l10n: git.pot: v2.10.0 round 1 (248 new, 56 removed)

    Generate po/git.pot from v2.10.0-rc0 for git v2.10.0 l10n round 1.

    Signed-off-by: Jiang Xin <worldhello.net@gmail.com>

You can get it from the usual place:

    https://github.com/git-l10n/git-po/

As how to update your XX.po and help to translate Git, please see
"Updating a XX.po file" and other sections in “po/README" file.

--
Jiang Xin

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-15 15:04 [L10N] Kickoff of translation for Git 2.10.0 round 1 Jiang Xin
@ 2016-08-20 16:01 ` Jean-Noël AVILA
  2016-08-20 18:03   ` Junio C Hamano
  2016-08-25  5:24   ` [L10N] Kickoff of translation for Git 2.10.0 round 1 Alex Henrie
  0 siblings, 2 replies; 15+ messages in thread
From: Jean-Noël AVILA @ 2016-08-20 16:01 UTC (permalink / raw)
  To: Jiang Xin
  Cc: Alexander Shopov, Alex Henrie, Ralf Thielow, Marco Paolone,
	Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev, Peter Krefting,
	Trần Ngọc Quân, Nelson Martell, Brian Gesiak,
	Junio C Hamano, Git List

Hi all,

Before anyone tries to localize this round, I'd like to make some preliminary 
comments:

1.  In config.c, the changes to the function die_bad_number tried to flatten the 
translated strings (no message building logic). I think it went too far, and 
the reason of the failure can be factorized so that we don't have to 
retranslate each time. I might be wrong on this one, but I have no example of 
language where we would need differentiated error reasons.

2.  in sequencer.c, there is a mistake in the original string to translate 
"Cannot revert during a another revert"

3. git-rebase--interactive, in this_nth_commit_message and 
skip_nth_commit_message are not localizable, because the logic of declination 
of numeral attributes is in the code and is really oriented towards English 
and doesn't make sense for other languages (with 28 strings to translate !). 
In this case, I would suggest to step back and just have a single string per 
function.

If translators can quickly agree on these issues and maybe others I haven't 
seen, I can prepare a patch for review this weekend.

BR

Jean-Noël (french translation)




^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-20 16:01 ` Jean-Noël AVILA
@ 2016-08-20 18:03   ` Junio C Hamano
  2016-08-20 18:38     ` Jean-Noël AVILA
  2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
  2016-08-25  5:24   ` [L10N] Kickoff of translation for Git 2.10.0 round 1 Alex Henrie
  1 sibling, 2 replies; 15+ messages in thread
From: Junio C Hamano @ 2016-08-20 18:03 UTC (permalink / raw)
  To: Jean-Noël AVILA
  Cc: Jiang Xin, Alexander Shopov, Alex Henrie, Ralf Thielow,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Nelson Martell,
	Brian Gesiak, Git List

Jean-Noël AVILA <jn.avila@free.fr> writes:

> 1.  In config.c, the changes to the function die_bad_number tried to flatten the 
> translated strings (no message building logic). I think it went too far, and 
> the reason of the failure can be factorized so that we don't have to 
> retranslate each time. I might be wrong on this one, but I have no example of 
> language where we would need differentiated error reasons.

I do not have a strong opinion on this one.  I think it is an
attempt to avoid language-lego.

> 2.  in sequencer.c, there is a mistake in the original string to translate 
> "Cannot revert during a another revert"

This should be corrected. Thanks for spotting.

> 3. git-rebase--interactive, in this_nth_commit_message and 
> skip_nth_commit_message are not localizable,

As the "TRANSLATORS" comment alludes to, "This is the Nth thing" can
be rephrased to "This is the thing N" or "This is the thing #N"
easily, and if that form without ordinal is acceptable for many
languages, we should say that it is also OK in C-locale without
translation.  So I agree that the recent change was pointless (even
though the result may be localizable).

In an ideal world, I would imagine that this would be done by using
Q_("This is the first thing", "This is the thing #%d", nth) aka
ngettext, but

    (1) I haven't seen ngettext used from shell scripts; and

    (2) I do not think po files are set up to express "for this
        message, this language has 4 variants and here are the local
        rules to decide which one to use depending on the number,
        but the rules apply only to this message".  The Plural-Forms
        rule [*1*] seems to be global to a .po file, unfortunately.

so I do not think we cannot do it with ngettext().

[Reference]

*1* https://www.gnu.org/savannah-checkouts/gnu/gettext/manual/html_node/Plural-forms.html


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-20 18:03   ` Junio C Hamano
@ 2016-08-20 18:38     ` Jean-Noël AVILA
  2016-08-21 15:45       ` Jiang Xin
  2016-08-23 15:58       ` Junio C Hamano
  2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
  1 sibling, 2 replies; 15+ messages in thread
From: Jean-Noël AVILA @ 2016-08-20 18:38 UTC (permalink / raw)
  To: Junio C Hamano
  Cc: Jiang Xin, Alexander Shopov, Alex Henrie, Ralf Thielow,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Nelson Martell,
	Brian Gesiak, Git List

On samedi 20 août 2016 11:03:00 CEST Junio C Hamano wrote:
> Jean-Noël AVILA <jn.avila@free.fr> writes:
> > 1.  In config.c, the changes to the function die_bad_number tried to
> > flatten the translated strings (no message building logic). I think it
> > went too far, and the reason of the failure can be factorized so that we
> > don't have to retranslate each time. I might be wrong on this one, but I
> > have no example of language where we would need differentiated error
> > reasons.
> 
> I do not have a strong opinion on this one.  I think it is an
> attempt to avoid language-lego.

No problem with the changes for blob, files, command line. It's just about 
dividing by two the number of strings to translate by factorizing "out of 
range" and "invalid unit", which are invariable anyway.  		

> 
> > 2.  in sequencer.c, there is a mistake in the original string to translate
> > "Cannot revert during a another revert"
> 
> This should be corrected. Thanks for spotting.

I also spotted a missing capitals. Will propose a patch.

> 
> > 3. git-rebase--interactive, in this_nth_commit_message and
> > skip_nth_commit_message are not localizable,
> 
> As the "TRANSLATORS" comment alludes to, "This is the Nth thing" can
> be rephrased to "This is the thing N" or "This is the thing #N"
> easily, and if that form without ordinal is acceptable for many
> languages, we should say that it is also OK in C-locale without
> translation.  So I agree that the recent change was pointless (even
> though the result may be localizable).
> 
> In an ideal world, I would imagine that this would be done by using
> Q_("This is the first thing", "This is the thing #%d", nth) aka
> ngettext, but
> 
>     (1) I haven't seen ngettext used from shell scripts; and
> 

There's a use_ngettext macro

>     (2) I do not think po files are set up to express "for this
>         message, this language has 4 variants and here are the local
>         rules to decide which one to use depending on the number,
>         but the rules apply only to this message".  The Plural-Forms
>         rule [*1*] seems to be global to a .po file, unfortunately.
> 


> so I do not think we cannot do it with ngettext().
> 

Let's cut it like this : first ten are literally translated, the following ones 
fall back to a general rule. All languages are treated equally. With more than 
10 squashed commit, you no longer really care if the numbering is pedantically 
correct.

> [Reference]
> 
> *1*
> https://www.gnu.org/savannah-checkouts/gnu/gettext/manual/html_node/Plural-> forms.html



^ permalink raw reply	[flat|nested] 15+ messages in thread

* [PATCH 1/3] i18n: fix typos for translation
  2016-08-20 18:03   ` Junio C Hamano
  2016-08-20 18:38     ` Jean-Noël AVILA
@ 2016-08-21 14:50     ` Jean-Noel Avila
  2016-08-21 14:50       ` [PATCH 2/3] i18n: fix git rebase interactive commit messages Jean-Noel Avila
                         ` (2 more replies)
  1 sibling, 3 replies; 15+ messages in thread
From: Jean-Noel Avila @ 2016-08-21 14:50 UTC (permalink / raw)
  To: git; +Cc: Jean-Noel Avila

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
---
 bisect.c    | 10 +++++-----
 sequencer.c |  2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/bisect.c b/bisect.c
index 6f512c2..b9a0701 100644
--- a/bisect.c
+++ b/bisect.c
@@ -760,7 +760,7 @@ static void handle_skipped_merge_base(const unsigned char *mb)
 	char *bad_hex = oid_to_hex(current_bad_oid);
 	char *good_hex = join_sha1_array_hex(&good_revs, ' ');
 
-	warning(_("the merge base between %s and [%s] "
+	warning(_("The merge base between %s and [%s] "
 		"must be skipped.\n"
 		"So we cannot be sure the first %s commit is "
 		"between %s and %s.\n"
@@ -846,7 +846,7 @@ static void check_good_are_ancestors_of_bad(const char *prefix, int no_checkout)
 	int fd;
 
 	if (!current_bad_oid)
-		die(_("a %s revision is needed"), term_bad);
+		die(_("A %s revision is needed"), term_bad);
 
 	/* Check if file BISECT_ANCESTORS_OK exists. */
 	if (!stat(filename, &st) && S_ISREG(st.st_mode))
@@ -863,7 +863,7 @@ static void check_good_are_ancestors_of_bad(const char *prefix, int no_checkout)
 	/* Create file BISECT_ANCESTORS_OK. */
 	fd = open(filename, O_CREAT | O_TRUNC | O_WRONLY, 0600);
 	if (fd < 0)
-		warning_errno(_("could not create file '%s'"),
+		warning_errno(_("Could not create file '%s'"),
 			      filename);
 	else
 		close(fd);
@@ -914,7 +914,7 @@ void read_bisect_terms(const char **read_bad, const char **read_good)
 			*read_good = "good";
 			return;
 		} else {
-			die_errno(_("could not read file '%s'"), filename);
+			die_errno(_("Could not read file '%s'"), filename);
 		}
 	} else {
 		strbuf_getline_lf(&str, fp);
@@ -944,7 +944,7 @@ int bisect_next_all(const char *prefix, int no_checkout)
 
 	read_bisect_terms(&term_bad, &term_good);
 	if (read_bisect_refs())
-		die(_("reading bisect refs failed"));
+		die(_("Reading bisect refs failed"));
 
 	check_good_are_ancestors_of_bad(prefix, no_checkout);
 
diff --git a/sequencer.c b/sequencer.c
index 2e9c7d0..3804fa9 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -702,7 +702,7 @@ static struct commit *parse_insn_line(char *bol, char *eol, struct replay_opts *
 	if (action != opts->action) {
 		if (action == REPLAY_REVERT)
 		      error((opts->action == REPLAY_REVERT)
-			    ? _("Cannot revert during a another revert.")
+			    ? _("Cannot revert during another revert.")
 			    : _("Cannot revert during a cherry-pick."));
 		else
 		      error((opts->action == REPLAY_REVERT)
-- 
2.10.0.rc0.37.gd7d1c14.dirty


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 2/3] i18n: fix git rebase interactive commit messages
  2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
@ 2016-08-21 14:50       ` Jean-Noel Avila
  2016-08-21 14:50       ` [PATCH 3/3] i18n: simplify numeric error reporting Jean-Noel Avila
  2016-08-23 16:06       ` [PATCH 1/3] i18n: fix typos for translation Junio C Hamano
  2 siblings, 0 replies; 15+ messages in thread
From: Jean-Noel Avila @ 2016-08-21 14:50 UTC (permalink / raw)
  To: git; +Cc: Jean-Noel Avila

For proper i18n, the logic cannot embed english specific processing.

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
---
 git-rebase--interactive.sh | 16 ----------------
 1 file changed, 16 deletions(-)

diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index e2da524..7baf5f4 100644
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -415,14 +415,6 @@ this_nth_commit_message () {
 	8) gettext "This is the 8th commit message:";;
 	9) gettext "This is the 9th commit message:";;
 	10) gettext "This is the 10th commit message:";;
-	# TRANSLATORS: if the language you are translating into
-	# doesn't allow you to compose a sentence in this fashion,
-	# consider translating as if this and the following few strings
-	# were "This is the commit message ${n}:"
-	*1[0-9]|*[04-9]) eval_gettext "This is the \${n}th commit message:";;
-	*1) eval_gettext "This is the \${n}st commit message:";;
-	*2) eval_gettext "This is the \${n}nd commit message:";;
-	*3) eval_gettext "This is the \${n}rd commit message:";;
 	*) eval_gettext "This is the commit message \${n}:";;
 	esac
 }
@@ -439,14 +431,6 @@ skip_nth_commit_message () {
 	8) gettext "The 8th commit message will be skipped:";;
 	9) gettext "The 9th commit message will be skipped:";;
 	10) gettext "The 10th commit message will be skipped:";;
-	# TRANSLATORS: if the language you are translating into
-	# doesn't allow you to compose a sentence in this fashion,
-	# consider translating as if this and the following few strings
-	# were "The commit message ${n} will be skipped:"
-	*1[0-9]|*[04-9]) eval_gettext "The \${n}th commit message will be skipped:";;
-	*1) eval_gettext "The \${n}st commit message will be skipped:";;
-	*2) eval_gettext "The \${n}nd commit message will be skipped:";;
-	*3) eval_gettext "The \${n}rd commit message will be skipped:";;
 	*) eval_gettext "The commit message \${n} will be skipped:";;
 	esac
 }
-- 
2.10.0.rc0.37.gd7d1c14.dirty


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 3/3] i18n: simplify numeric error reporting
  2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
  2016-08-21 14:50       ` [PATCH 2/3] i18n: fix git rebase interactive commit messages Jean-Noel Avila
@ 2016-08-21 14:50       ` Jean-Noel Avila
  2016-08-24 15:48         ` Junio C Hamano
  2016-08-23 16:06       ` [PATCH 1/3] i18n: fix typos for translation Junio C Hamano
  2 siblings, 1 reply; 15+ messages in thread
From: Jean-Noel Avila @ 2016-08-21 14:50 UTC (permalink / raw)
  To: git; +Cc: Jean-Noel Avila

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
---
 config.c | 43 +++++++++++++++----------------------------
 1 file changed, 15 insertions(+), 28 deletions(-)

diff --git a/config.c b/config.c
index 584cacf..e33c703 100644
--- a/config.c
+++ b/config.c
@@ -655,43 +655,30 @@ static void die_bad_number(const char *name, const char *value)
 	if (!value)
 		value = "";
 
+	const char * error_type = (errno == ERANGE)? _("out of range"):_("invalid unit");
 	if (!(cf && cf->name))
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s': out of range")
-		    : _("bad numeric config value '%s' for '%s': invalid unit"),
-		    value, name);
+		die(_("bad numeric config value '%s' for '%s': %s"),
+		    value, name, error_type);
 
 	switch (cf->origin_type) {
 	case CONFIG_ORIGIN_BLOB:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in blob %s: out of range")
-		    : _("bad numeric config value '%s' for '%s' in blob %s: invalid unit"),
-		    value, name, cf->name);
+		die(_("bad numeric config value '%s' for '%s' in blob %s: %s"),
+		    value, name, cf->name, error_type);
 	case CONFIG_ORIGIN_FILE:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in file %s: out of range")
-		    : _("bad numeric config value '%s' for '%s' in file %s: invalid unit"),
-		    value, name, cf->name);
+		die(_("bad numeric config value '%s' for '%s' in file %s: %s"),
+		    value, name, cf->name, error_type);
 	case CONFIG_ORIGIN_STDIN:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in standard input: out of range")
-		    : _("bad numeric config value '%s' for '%s' in standard input: invalid unit"),
-		    value, name);
+		die(_("bad numeric config value '%s' for '%s' in standard input: %s"),
+		    value, name, error_type);
 	case CONFIG_ORIGIN_SUBMODULE_BLOB:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in submodule-blob %s: out of range")
-		    : _("bad numeric config value '%s' for '%s' in submodule-blob %s: invalid unit"),
-		    value, name, cf->name);
+		die(_("bad numeric config value '%s' for '%s' in submodule-blob %s: %s"),
+		    value, name, cf->name, error_type);
 	case CONFIG_ORIGIN_CMDLINE:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in command line %s: out of range")
-		    : _("bad numeric config value '%s' for '%s' in command line %s: invalid unit"),
-		    value, name, cf->name);
+		die(_("bad numeric config value '%s' for '%s' in command line %s: %s"),
+		    value, name, cf->name, error_type);
 	default:
-		die(errno == ERANGE
-		    ? _("bad numeric config value '%s' for '%s' in %s: out of range")
-		    : _("bad numeric config value '%s' for '%s' in %s: invalid unit"),
-		    value, name, cf->name);
+		die(_("bad numeric config value '%s' for '%s' in %s: %s"),
+		    value, name, cf->name, error_type);
 	}
 }
 
-- 
2.10.0.rc0.37.gd7d1c14.dirty


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-20 18:38     ` Jean-Noël AVILA
@ 2016-08-21 15:45       ` Jiang Xin
  2016-08-23 15:58       ` Junio C Hamano
  1 sibling, 0 replies; 15+ messages in thread
From: Jiang Xin @ 2016-08-21 15:45 UTC (permalink / raw)
  To: Jean-Noël AVILA
  Cc: Junio C Hamano, Alexander Shopov, Alex Henrie, Ralf Thielow,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Nelson Martell,
	Brian Gesiak, Git List

2016-08-21 2:38 GMT+08:00 Jean-Noël AVILA <jn.avila@free.fr>:
> On samedi 20 août 2016 11:03:00 CEST Junio C Hamano wrote:
>> Jean-Noël AVILA <jn.avila@free.fr> writes:
>> > 1.  In config.c, the changes to the function die_bad_number tried to
>> > flatten the translated strings (no message building logic). I think it
>> > went too far, and the reason of the failure can be factorized so that we
>> > don't have to retranslate each time. I might be wrong on this one, but I
>> > have no example of language where we would need differentiated error
>> > reasons.
>>
>> I do not have a strong opinion on this one.  I think it is an
>> attempt to avoid language-lego.
>
> No problem with the changes for blob, files, command line. It's just about
> dividing by two the number of strings to translate by factorizing "out of
> range" and "invalid unit", which are invariable anyway.

I agree with you.  It maybe not a good solution to expanded string "reason"
in commit 1b8132d:

    -       const char *reason = errno == ERANGE ?
    -                            "out of range" :
    -                            "invalid unit";


>> > 3. git-rebase--interactive, in this_nth_commit_message and
>> > skip_nth_commit_message are not localizable,
>>
>> As the "TRANSLATORS" comment alludes to, "This is the Nth thing" can
>> be rephrased to "This is the thing N" or "This is the thing #N"
>> easily, and if that form without ordinal is acceptable for many
>> languages, we should say that it is also OK in C-locale without
>> translation.  So I agree that the recent change was pointless (even
>> though the result may be localizable).
>>
>> In an ideal world, I would imagine that this would be done by using
>> Q_("This is the first thing", "This is the thing #%d", nth) aka
>> ngettext, but
>>
>>     (1) I haven't seen ngettext used from shell scripts; and
>>
> There's a use_ngettext macro
>
>>     (2) I do not think po files are set up to express "for this
>>         message, this language has 4 variants and here are the local
>>         rules to decide which one to use depending on the number,
>>         but the rules apply only to this message".  The Plural-Forms
>>         rule [*1*] seems to be global to a .po file, unfortunately.
>>
>
>
>> so I do not think we cannot do it with ngettext().
>>
>
> Let's cut it like this : first ten are literally translated, the following ones
> fall back to a general rule. All languages are treated equally. With more than
> 10 squashed commit, you no longer really care if the numbering is pedantically
> correct.


It's boring to translate all these 30 messages, I prefer #N like:

    gettext "The commit message #\${n} will be skipped:"
    gettext "This is the commit message #\${n}:"


-- 
Jiang Xin

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-20 18:38     ` Jean-Noël AVILA
  2016-08-21 15:45       ` Jiang Xin
@ 2016-08-23 15:58       ` Junio C Hamano
  2016-08-23 18:16         ` Jean-Noël AVILA
  1 sibling, 1 reply; 15+ messages in thread
From: Junio C Hamano @ 2016-08-23 15:58 UTC (permalink / raw)
  To: Jean-Noël AVILA
  Cc: Jiang Xin, Alexander Shopov, Alex Henrie, Ralf Thielow,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Nelson Martell,
	Brian Gesiak, Git List

Jean-Noël AVILA <jn.avila@free.fr> writes:

>> > 3. git-rebase--interactive, in this_nth_commit_message and
>> > skip_nth_commit_message are not localizable,
>> 
>> As the "TRANSLATORS" comment alludes to, "This is the Nth thing" can
>> be rephrased to "This is the thing N" or "This is the thing #N"
>> easily, and if that form without ordinal is acceptable for many
>> languages, we should say that it is also OK in C-locale without
>> translation.  So I agree that the recent change was pointless (even
>> though the result may be localizable).
> ...
>> so I do not think we cannot do it with ngettext().
>
> Let's cut it like this : first ten are literally translated, the following ones 
> fall back to a general rule.

I actually once wrote "It is rare to squash dozens of commits into
one, so the first ten or dozen messages that spell the ordinals out
may be a good thing for readability", in the message you are
responding to, before realizing that the messages actually say
"1st", "2nd", etc., not "first", "second", etc., and scrapped that
part of the response.  I do not really see much point in forcing the
first ten to be translated differently.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH 1/3] i18n: fix typos for translation
  2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
  2016-08-21 14:50       ` [PATCH 2/3] i18n: fix git rebase interactive commit messages Jean-Noel Avila
  2016-08-21 14:50       ` [PATCH 3/3] i18n: simplify numeric error reporting Jean-Noel Avila
@ 2016-08-23 16:06       ` Junio C Hamano
  2016-08-24 15:44         ` Junio C Hamano
  2016-08-24 15:45         ` Junio C Hamano
  2 siblings, 2 replies; 15+ messages in thread
From: Junio C Hamano @ 2016-08-23 16:06 UTC (permalink / raw)
  To: Jean-Noel Avila; +Cc: git

Jean-Noel Avila <jn.avila@free.fr> writes:

> Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
> ---
>  bisect.c    | 10 +++++-----
>  sequencer.c |  2 +-
>  2 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/bisect.c b/bisect.c
> index 6f512c2..b9a0701 100644
> --- a/bisect.c
> +++ b/bisect.c
> @@ -760,7 +760,7 @@ static void handle_skipped_merge_base(const unsigned char *mb)
>  	char *bad_hex = oid_to_hex(current_bad_oid);
>  	char *good_hex = join_sha1_array_hex(&good_revs, ' ');
>  
> -	warning(_("the merge base between %s and [%s] "
> +	warning(_("The merge base between %s and [%s] "

I _think_ most these are not typos and must stay as they are.  From
time to time we try to clean things up, cf. 8c3ca351 (config:
lower-case first word of error strings, 2016-04-09).

The removal of "a" from "a another reviert" is good.  If you are
fixing the cases, you would want to do the correction the other way.

>  		"must be skipped.\n"
>  		"So we cannot be sure the first %s commit is "
>  		"between %s and %s.\n"
> @@ -846,7 +846,7 @@ static void check_good_are_ancestors_of_bad(const char *prefix, int no_checkout)
>  	int fd;
>  
>  	if (!current_bad_oid)
> -		die(_("a %s revision is needed"), term_bad);
> +		die(_("A %s revision is needed"), term_bad);
>  
>  	/* Check if file BISECT_ANCESTORS_OK exists. */
>  	if (!stat(filename, &st) && S_ISREG(st.st_mode))
> @@ -863,7 +863,7 @@ static void check_good_are_ancestors_of_bad(const char *prefix, int no_checkout)
>  	/* Create file BISECT_ANCESTORS_OK. */
>  	fd = open(filename, O_CREAT | O_TRUNC | O_WRONLY, 0600);
>  	if (fd < 0)
> -		warning_errno(_("could not create file '%s'"),
> +		warning_errno(_("Could not create file '%s'"),
>  			      filename);
>  	else
>  		close(fd);
> @@ -914,7 +914,7 @@ void read_bisect_terms(const char **read_bad, const char **read_good)
>  			*read_good = "good";
>  			return;
>  		} else {
> -			die_errno(_("could not read file '%s'"), filename);
> +			die_errno(_("Could not read file '%s'"), filename);
>  		}
>  	} else {
>  		strbuf_getline_lf(&str, fp);
> @@ -944,7 +944,7 @@ int bisect_next_all(const char *prefix, int no_checkout)
>  
>  	read_bisect_terms(&term_bad, &term_good);
>  	if (read_bisect_refs())
> -		die(_("reading bisect refs failed"));
> +		die(_("Reading bisect refs failed"));
>  
>  	check_good_are_ancestors_of_bad(prefix, no_checkout);
>  
> diff --git a/sequencer.c b/sequencer.c
> index 2e9c7d0..3804fa9 100644
> --- a/sequencer.c
> +++ b/sequencer.c
> @@ -702,7 +702,7 @@ static struct commit *parse_insn_line(char *bol, char *eol, struct replay_opts *
>  	if (action != opts->action) {
>  		if (action == REPLAY_REVERT)
>  		      error((opts->action == REPLAY_REVERT)
> -			    ? _("Cannot revert during a another revert.")
> +			    ? _("Cannot revert during another revert.")
>  			    : _("Cannot revert during a cherry-pick."));
>  		else
>  		      error((opts->action == REPLAY_REVERT)

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-23 15:58       ` Junio C Hamano
@ 2016-08-23 18:16         ` Jean-Noël AVILA
  0 siblings, 0 replies; 15+ messages in thread
From: Jean-Noël AVILA @ 2016-08-23 18:16 UTC (permalink / raw)
  To: Junio C Hamano
  Cc: Jiang Xin, Alexander Shopov, Alex Henrie, Ralf Thielow,
	Marco Paolone, Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev,
	Peter Krefting, Trần Ngọc Quân, Nelson Martell,
	Brian Gesiak, Git List

On mardi 23 août 2016 08:58:55 CEST Junio C Hamano wrote:

> > Let's cut it like this : first ten are literally translated, the following
> > ones fall back to a general rule.
> 
> I actually once wrote "It is rare to squash dozens of commits into
> one, so the first ten or dozen messages that spell the ordinals out
> may be a good thing for readability", in the message you are
> responding to, before realizing that the messages actually say
> "1st", "2nd", etc., not "first", "second", etc., and scrapped that
> part of the response.  I do not really see much point in forcing the
> first ten to be translated differently.

In fact, taking some advance on the patch, I made the translations and used 
full words in the translated language.
By majority of repliers, let's just use a single sentence for each case "use" 
or "skip". 

Will rerun the patch set.

JN

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH 1/3] i18n: fix typos for translation
  2016-08-23 16:06       ` [PATCH 1/3] i18n: fix typos for translation Junio C Hamano
@ 2016-08-24 15:44         ` Junio C Hamano
  2016-08-24 15:45         ` Junio C Hamano
  1 sibling, 0 replies; 15+ messages in thread
From: Junio C Hamano @ 2016-08-24 15:44 UTC (permalink / raw)
  To: Jean-Noel Avila; +Cc: git

Here comes suggested replacement for 1/3 and 2/3.

Let's not correct "C" in "Cannot" at this stage and leave them to
the next cycle; there are too many of them.

-- >8 --
From: Jean-Noel Avila <jn.avila@free.fr>
Date: Sun, 21 Aug 2016 16:50:37 +0200
Subject: [PATCH 1/3] i18n: fix typos for translation

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 sequencer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sequencer.c b/sequencer.c
index 2e9c7d0..3804fa9 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -702,7 +702,7 @@ static struct commit *parse_insn_line(char *bol, char *eol, struct replay_opts *
 	if (action != opts->action) {
 		if (action == REPLAY_REVERT)
 		      error((opts->action == REPLAY_REVERT)
-			    ? _("Cannot revert during a another revert.")
+			    ? _("Cannot revert during another revert.")
 			    : _("Cannot revert during a cherry-pick."));
 		else
 		      error((opts->action == REPLAY_REVERT)
-- 
2.10.0-rc1-130-gf5df0f2


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH 1/3] i18n: fix typos for translation
  2016-08-23 16:06       ` [PATCH 1/3] i18n: fix typos for translation Junio C Hamano
  2016-08-24 15:44         ` Junio C Hamano
@ 2016-08-24 15:45         ` Junio C Hamano
  1 sibling, 0 replies; 15+ messages in thread
From: Junio C Hamano @ 2016-08-24 15:45 UTC (permalink / raw)
  To: Jean-Noel Avila; +Cc: git, Jiang Xin

And here is the second one, using wording suggested by Jiang.

-- >8 -- 
From: Jean-Noel Avila <jn.avila@free.fr>
Date: Sun, 21 Aug 2016 16:50:38 +0200
Subject: [PATCH] i18n: fix git rebase interactive commit messages

For proper i18n, the logic cannot embed english specific processing.

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 git-rebase--interactive.sh | 45 +++------------------------------------------
 1 file changed, 3 insertions(+), 42 deletions(-)

diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index e2da524..7e558b0 100644
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -404,51 +404,12 @@ pick_one_preserving_merges () {
 
 this_nth_commit_message () {
 	n=$1
-	case "$n" in
-	1) gettext "This is the 1st commit message:";;
-	2) gettext "This is the 2nd commit message:";;
-	3) gettext "This is the 3rd commit message:";;
-	4) gettext "This is the 4th commit message:";;
-	5) gettext "This is the 5th commit message:";;
-	6) gettext "This is the 6th commit message:";;
-	7) gettext "This is the 7th commit message:";;
-	8) gettext "This is the 8th commit message:";;
-	9) gettext "This is the 9th commit message:";;
-	10) gettext "This is the 10th commit message:";;
-	# TRANSLATORS: if the language you are translating into
-	# doesn't allow you to compose a sentence in this fashion,
-	# consider translating as if this and the following few strings
-	# were "This is the commit message ${n}:"
-	*1[0-9]|*[04-9]) eval_gettext "This is the \${n}th commit message:";;
-	*1) eval_gettext "This is the \${n}st commit message:";;
-	*2) eval_gettext "This is the \${n}nd commit message:";;
-	*3) eval_gettext "This is the \${n}rd commit message:";;
-	*) eval_gettext "This is the commit message \${n}:";;
-	esac
+	eval_gettext "This is the commit message #\${n}:"
 }
+
 skip_nth_commit_message () {
 	n=$1
-	case "$n" in
-	1) gettext "The 1st commit message will be skipped:";;
-	2) gettext "The 2nd commit message will be skipped:";;
-	3) gettext "The 3rd commit message will be skipped:";;
-	4) gettext "The 4th commit message will be skipped:";;
-	5) gettext "The 5th commit message will be skipped:";;
-	6) gettext "The 6th commit message will be skipped:";;
-	7) gettext "The 7th commit message will be skipped:";;
-	8) gettext "The 8th commit message will be skipped:";;
-	9) gettext "The 9th commit message will be skipped:";;
-	10) gettext "The 10th commit message will be skipped:";;
-	# TRANSLATORS: if the language you are translating into
-	# doesn't allow you to compose a sentence in this fashion,
-	# consider translating as if this and the following few strings
-	# were "The commit message ${n} will be skipped:"
-	*1[0-9]|*[04-9]) eval_gettext "The \${n}th commit message will be skipped:";;
-	*1) eval_gettext "The \${n}st commit message will be skipped:";;
-	*2) eval_gettext "The \${n}nd commit message will be skipped:";;
-	*3) eval_gettext "The \${n}rd commit message will be skipped:";;
-	*) eval_gettext "The commit message \${n} will be skipped:";;
-	esac
+	eval_gettext "The commit message #\${n} will be skipped:"
 }
 
 update_squash_messages () {
-- 
2.10.0-rc1-130-gf5df0f2


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH 3/3] i18n: simplify numeric error reporting
  2016-08-21 14:50       ` [PATCH 3/3] i18n: simplify numeric error reporting Jean-Noel Avila
@ 2016-08-24 15:48         ` Junio C Hamano
  0 siblings, 0 replies; 15+ messages in thread
From: Junio C Hamano @ 2016-08-24 15:48 UTC (permalink / raw)
  To: Jean-Noel Avila; +Cc: git

I'll squash this in to avoid compilation breakage.  We do not allow
decl-after-stmt.

Thanks.

 config.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/config.c b/config.c
index e33c703..0dfed68 100644
--- a/config.c
+++ b/config.c
@@ -652,10 +652,11 @@ int git_parse_ulong(const char *value, unsigned long *ret)
 NORETURN
 static void die_bad_number(const char *name, const char *value)
 {
+	const char * error_type = (errno == ERANGE)? _("out of range"):_("invalid unit");
+
 	if (!value)
 		value = "";
 
-	const char * error_type = (errno == ERANGE)? _("out of range"):_("invalid unit");
 	if (!(cf && cf->name))
 		die(_("bad numeric config value '%s' for '%s': %s"),
 		    value, name, error_type);

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [L10N] Kickoff of translation for Git 2.10.0 round 1
  2016-08-20 16:01 ` Jean-Noël AVILA
  2016-08-20 18:03   ` Junio C Hamano
@ 2016-08-25  5:24   ` Alex Henrie
  1 sibling, 0 replies; 15+ messages in thread
From: Alex Henrie @ 2016-08-25  5:24 UTC (permalink / raw)
  To: Jean-Noël AVILA
  Cc: Jiang Xin, Alexander Shopov, Ralf Thielow, Marco Paolone,
	Changwoo Ryu, Marco Sousa, Dimitriy Ryazantcev, Peter Krefting,
	Trần Ngọc Quân, Nelson Martell, Brian Gesiak,
	Junio C Hamano, Git List

2016-08-20 10:01 GMT-06:00 Jean-Noël AVILA <jn.avila@free.fr>:
> 2.  in sequencer.c, there is a mistake in the original string to translate
> "Cannot revert during a another revert"

There's also "In both case" in git-rebase--interactive.sh.

-Alex

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2016-08-25  5:25 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-15 15:04 [L10N] Kickoff of translation for Git 2.10.0 round 1 Jiang Xin
2016-08-20 16:01 ` Jean-Noël AVILA
2016-08-20 18:03   ` Junio C Hamano
2016-08-20 18:38     ` Jean-Noël AVILA
2016-08-21 15:45       ` Jiang Xin
2016-08-23 15:58       ` Junio C Hamano
2016-08-23 18:16         ` Jean-Noël AVILA
2016-08-21 14:50     ` [PATCH 1/3] i18n: fix typos for translation Jean-Noel Avila
2016-08-21 14:50       ` [PATCH 2/3] i18n: fix git rebase interactive commit messages Jean-Noel Avila
2016-08-21 14:50       ` [PATCH 3/3] i18n: simplify numeric error reporting Jean-Noel Avila
2016-08-24 15:48         ` Junio C Hamano
2016-08-23 16:06       ` [PATCH 1/3] i18n: fix typos for translation Junio C Hamano
2016-08-24 15:44         ` Junio C Hamano
2016-08-24 15:45         ` Junio C Hamano
2016-08-25  5:24   ` [L10N] Kickoff of translation for Git 2.10.0 round 1 Alex Henrie

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).