summaryrefslogtreecommitdiff
path: root/diff.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-09-17 15:57:22 -0700
committerJunio C Hamano <gitster@pobox.com>2012-09-17 15:57:22 -0700
commit9e40b6e59573dfd58746f9b1aafd5305ffe3c53f (patch)
treef08eb04b31633ba2f3b9058b89af1324702e8c03 /diff.c
parentd6fb62474ee4772ceca815122f21a4198e4f22f2 (diff)
parent218adaaaa064c436115dbcd5705a0e2c42e90a25 (diff)
downloadgit-9e40b6e59573dfd58746f9b1aafd5305ffe3c53f.tar.gz
Merge branch 'nd/maint-diffstat-summary'
Earlier we made the diffstat summary line that shows the number of lines added/deleted localizable, but it was found irritating having to see them in various languages on a list whose discussion language is English. The original had trivial thinko in reverting Q_(), which has been fixed. * nd/maint-diffstat-summary: Revert diffstat back to English
Diffstat (limited to 'diff.c')
-rw-r--r--diff.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/diff.c b/diff.c
index e6846ca750..32142dba64 100644
--- a/diff.c
+++ b/diff.c
@@ -1398,11 +1398,11 @@ int print_stat_summary(FILE *fp, int files, int insertions, int deletions)
if (!files) {
assert(insertions == 0 && deletions == 0);
- return fprintf(fp, "%s\n", _(" 0 files changed"));
+ return fprintf(fp, "%s\n", " 0 files changed");
}
strbuf_addf(&sb,
- Q_(" %d file changed", " %d files changed", files),
+ (files == 1) ? " %d file changed" : " %d files changed",
files);
/*
@@ -1419,8 +1419,7 @@ int print_stat_summary(FILE *fp, int files, int insertions, int deletions)
* do not translate it.
*/
strbuf_addf(&sb,
- Q_(", %d insertion(+)", ", %d insertions(+)",
- insertions),
+ (insertions == 1) ? ", %d insertion(+)" : ", %d insertions(+)",
insertions);
}
@@ -1430,8 +1429,7 @@ int print_stat_summary(FILE *fp, int files, int insertions, int deletions)
* do not translate it.
*/
strbuf_addf(&sb,
- Q_(", %d deletion(-)", ", %d deletions(-)",
- deletions),
+ (deletions == 1) ? ", %d deletion(-)" : ", %d deletions(-)",
deletions);
}
strbuf_addch(&sb, '\n');