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

Re: Merge-friendly text-based data storage

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 26, 2012, 18:17 UTC
Message-ID
<7vfwcvp6pi.fsf@alter.siamese.dyndns.org>
In-Reply-To
<CAD77+gRTv4Aq_4FLAQcD9E0p7VBD7h6hQq3CJ9Wo5DU9Zjt+Hg@mail.gmail.com>
Richard Hartmann <richih.mailinglist@gmail.com> writes:
> As long as there are no lines that start with the same file name, this
> file format would allow for efficient merging _if_ git has an internal
> concept of line identifiers.

You can write a custom low-level merge driver, and use the attribute system to mark that your file is meant to be handled by that ll-merge driver. There is no need for Git to have "an internal concept of line identifiers".

It may be of interest to run "git help attributes" and read up on "Defining a custom merge driver" section.

Previous: Richard HartmannNext: Richard Hartmann
Message 2 of 8 in “Merge-friendly text-based data storage”
  1. Richard HartmannMar 26, 2012
  2. Junio C HamanoMar 26, 2012
  3. Richard HartmannMar 26, 2012
  4. Junio C HamanoMar 26, 2012
  5. Holger HellmuthMar 27, 2012
  6. Richard HartmannMar 27, 2012
  7. Junio C HamanoMar 27, 2012
  8. Holger HellmuthMar 27, 2012

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.