git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] setup: split "extensions found" messages into singular and plural

From
Alex Henrie <alexhenrie24@gmail.com>
Date
May 18, 2021, 06:19 UTC
Message-ID
<20210518061917.57556-1-alexhenrie24@gmail.com>
It's easier to translate this way.
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
---
 setup.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/setup.c b/setup.c
index 59e2facd9d..ead2f80cd8 100644
--- a/setup.c
+++ b/setup.c
@@ -666,7 +666,9 @@ int verify_repository_format(const struct repository_format *format,
 	if (format->version >= 1 && format->unknown_extensions.nr) {
 		int i;
 
-		strbuf_addstr(err, _("unknown repository extensions found:"));
+		strbuf_addstr(err, Q_("unknown repository extension found:",
+				      "unknown repository extensions found:",
+				      format->unknown_extensions.nr));
 
 		for (i = 0; i < format->unknown_extensions.nr; i++)
 			strbuf_addf(err, "\n\t%s",
@@ -678,7 +680,9 @@ int verify_repository_format(const struct repository_format *format,
 		int i;
 
 		strbuf_addstr(err,
-			      _("repo version is 0, but v1-only extensions found:"));
+			      Q_("repo version is 0, but v1-only extension found:",
+				 "repo version is 0, but v1-only extensions found:",
+				 format->v1_only_extensions.nr));
 
 		for (i = 0; i < format->v1_only_extensions.nr; i++)
 			strbuf_addf(err, "\n\t%s",
-- 
2.31.1
Next: Jeff King
Message 1 of 3 in “setup: split "extensions found" messages into singular and plural”
  1. setup: split "extensions found" messages into singular and pluralAlex Henrie, May 18, 2021
  2. Jeff KingMay 18, 2021
  3. Michal SuchánekMay 18, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.