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

Re: Merge made by recursive?

From
Jeff King <peff@peff.net>
Date
May 25, 2011, 21:02 UTC
Message-ID
<20110525210254.GA29716@sigill.intra.peff.net>
In-Reply-To
<7vzkma1p95.fsf@alter.siamese.dyndns.org>
On Wed, May 25, 2011 at 01:47:34PM -0700, Junio C Hamano wrote:
Show 5 quoted lines
> I am reluctant to do this (including the rewording of the end-user facing
> message) until we decide what to do with the reflog. Right now, I think no
> tool looks at the reflog, but contaminating the reflog with translatable
> messages mean that we will never be able to support "3 merges ago" just
> like we support "the previous branch".
The reflog messages look like:
  merge $branch: Merge made by recursive.

So it seems to me that we could localize everything after the colon and still do "3 merges ago". The only thing you would be losing is a machine-readable description of which strategy was used. In practice, I'm not sure how much it matters.

But for others, like:
  checkout: moving from $old to $new
a localized version loses useful information.
> Either we split the messages into two, one translatable and given to the
> end user and the other untranslatable and sent to the reflog,

That seems like the safe choice for now, as it still opens the possibility of localizing reflogs later if people care to do so. Being a native English speaker, I have no clue how much people actually care about localized reflog entries.

> place in reflog entry where we can hide machine readable and stable
> representation of what happened and store both the end-user facing message
> and the machine readable one separately. In the longer term I would prefer
> the latter.

If we assume that reflog entries are machine-readable (or at least _some_ of them that are generated by a few well-known git programs), you could always translate on the fly while displaying them.

That solves the storage question, and it allows two people with different language preferences to both read the same reflog. And the implementation probably wouldn't be too hard, since we'd only have to match a few well-known strings, and we could display anything we didn't match as it appears in the reflog.

-Peff
Previous: Junio C HamanoNext: Jeff King
Message 8 of 10 in “Merge made by recursive?”
  1. Shawn LigockiMay 25, 2011
  2. Ramkumar RamachandraMay 25, 2011
  3. Jakub NarebskiMay 25, 2011
  4. Junio C HamanoMay 25, 2011
  5. Jeff KingMay 25, 2011
  6. Junio C HamanoMay 25, 2011
  7. Junio C HamanoMay 25, 2011
  8. Jeff KingMay 25, 2011
  9. Jeff KingMay 25, 2011
  10. Jeff KingMay 25, 2011

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.