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

[Outreachy] Microproject: use Q_() in builtin/checkout.c

From
MMMuritala Mudi <ibnmuhyideen95@gmail.com>
Date
Oct 21, 2026, 04:18 UTC
Message-ID
<CAO=0-S64w=n47n6yfYoKJie2aFi+T88Sp_qPmFe2RW0xWEwcdQ@mail.gmail.com>
Hi Usman, Christian and Siddharth,

Thank you Usman for the welcome. I took some time to look into the microproject I want to work on and one that got my interest is the Q_() pluralization microproject. I will like to work on builtin/checkout.c. I searched the list archive and I didn't see anyone working on this file yet.

I noticed two places that can get improved with Q_():

Line 1088, " ... and %d more.\n": this is at the end of the warning Git shows when someone leaves a detached HEAD and so commits might be left behind. Git lists up to four commits and then shows this line for the rest.

Line 1492, "only one reference expected, %d given.": this appears when more than one reference is given before --, e.g. git checkout a b --. In both cases the number is always 2 or more, so in English the plural is always shown. But for languages like Polish, which have different plural forms for 2-4 and for 5 and above, it will be inconsistent to use the same form for all cases.

In po/pl.po, the first message currently has only one translation slot. So using Q_() can let have proper translation.

I noticed that line 1405 in builtin/checkout.c has the same issue. The same message also appears in builtin/worktree.c at lines 812 and 951.

So I have two questions:
1. Is it OK to convert these messages to Q_(), even though English
will always show the plural?
2. Should I also include line 1405 in the patch, which will mean
changing the same message in builtin/worktree.c
as well, or should I keep the patch just limited to the first two
messages for now

Regards, Mudi

Next: kerylefondji7@gmail.com
Message 1 of 5 in “[Outreachy] Microproject: use Q_() in builtin/checkout.c”
  1. Muritala MudiOct 21, 2026
  2. kerylefondji7@gmail.comOct 21, 2026
  3. Tuomas AholaOct 21, 2026
  4. Tanga JorisOct 21, 2026
  5. Muritala MudiOct 22, 2026

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.