git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jiang Xin <worldhello.net@gmail.com>
To: "Junio C Hamano" <gitster@pobox.com>,
	"Nguyễn Thái Ngọc Duy" <pclouds@gmail.co>
Cc: Git List <git@vger.kernel.org>, Jiang Xin <worldhello.net@gmail.com>
Subject: [PATCH] i18n: make the translation of -u advise in one go
Date: Fri, 12 Apr 2013 10:46:26 +0800	[thread overview]
Message-ID: <4003e29bb04b122897cefe2a8057266e2428dce5.1365734618.git.worldhello.net@gmail.com> (raw)

The advise (consider use of -u when read_directory takes too long) is
separated into 3 different status_printf_ln() calls, and which brings
trouble for translators.

Since status_vprintf() called by status_printf_ln() can handle eol in
buffer, we could simply join these lines into one paragraph.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
---
 wt-status.c | 14 +++++---------
 1 file changed, 5 insertions(+), 9 deletions(-)

diff --git a/wt-status.c b/wt-status.c
index 09416..f0d3 100644
--- a/wt-status.c
+++ b/wt-status.c
@@ -1223,16 +1223,12 @@ void wt_status_print(struct wt_status *s)
 		if (s->show_ignored_files)
 			wt_status_print_other(s, &s->ignored, _("Ignored files"), "add -f");
 		if (advice_status_u_option && 2000 < s->untracked_in_ms) {
-			status_printf_ln(s, GIT_COLOR_NORMAL, "");
 			status_printf_ln(s, GIT_COLOR_NORMAL,
-				 _("It took %.2f seconds to enumerate untracked files."
-				   "  'status -uno'"),
-				 s->untracked_in_ms / 1000.0);
-			status_printf_ln(s, GIT_COLOR_NORMAL,
-				 _("may speed it up, but you have to be careful not"
-				   " to forget to add"));
-			status_printf_ln(s, GIT_COLOR_NORMAL,
-				 _("new files yourself (see 'git help status')."));
+					 _("\n"
+					   "It took %.2f seconds to enumerate untracked files. 'status -uno'\n"
+					   "may speed it up, but you have to be careful not to forget to add\n"
+					   "new files yourself (see 'git help status')."),
+					 s->untracked_in_ms / 1000.0);
 		}
 	} else if (s->commitable)
 		status_printf_ln(s, GIT_COLOR_NORMAL, _("Untracked files not listed%s"),
-- 
1.8.2.1.347.g1003b3a.dirty

             reply	other threads:[~2013-04-12  2:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-12  2:46 Jiang Xin [this message]
2013-04-12  2:53 ` [PATCH] i18n: make the translation of -u advise in one go Eric Sunshine
2013-04-12  2:55 ` Jonathan Nieder
2013-04-12  3:53   ` [PATCH v2] i18n: make the translation of -u advice " Jiang Xin

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=4003e29bb04b122897cefe2a8057266e2428dce5.1365734618.git.worldhello.net@gmail.com \
    --to=worldhello.net@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=pclouds@gmail.co \
    /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 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 NNTP newsgroup(s).