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

RFD: best way to automatically rewrite a git DAG as a linear history?

From
Jon Seymour <jon.seymour@gmail.com>
Date
Feb 18, 2010, 02:35 UTC
Message-ID
<2cfc40321002171835j107d2cdcr5f7667d769bf391e@mail.gmail.com>

Does the git toolset currently support rewriting a restricted git DAG as a linear history in a completely automated way?

I understand that git rebase --root will attempt to rebase a DAG, but as far as I can tell any conflicts that occur during the rebase require a manual intervention to correct. My goal is a completely automated rewrite.

I guess some might be sceptical that a sane automated rewrite is impossible, but I am insane enough to think it might actually be possible.

I have prototype that implements an algorithm that does this [ for a restricted class of DAG of interest to me ], so I can't be completely insane, but if other people have already knocked the corners of this particular wheel, I'd be interested to learn of their efforts.

Regards.
jon
Next: Jeff King
Message 1 of 11 in “RFD: best way to automatically rewrite a git DAG as a linear history?”
  1. Jon SeymourFeb 18, 2010
  2. Jeff KingFeb 18, 2010
  3. Avery PennarunFeb 18, 2010
  4. Jon SeymourFeb 19, 2010
  5. Avery PennarunFeb 19, 2010
  6. Jon SeymourFeb 19, 2010
  7. Avery PennarunFeb 19, 2010
  8. Jon SeymourFeb 20, 2010
  9. Avery PennarunFeb 20, 2010
  10. Jon SeymourFeb 21, 2010
  11. Jon SeymourFeb 21, 2010

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.