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

Re: help moving boost.org to git

From
Avery Pennarun <apenwarr@gmail.com>
Date
Jul 6, 2010, 18:13 UTC
Message-ID
<AANLkTikfTFw_UdV1ia58MbWxH4h8TJAr-Y5WPvlXCjeJ@mail.gmail.com>
In-Reply-To
<4C336F3D.1010906@boostpro.com>
On Tue, Jul 6, 2010 at 2:00 PM, Eric Niebler <eric@boostpro.com> wrote:
Show 8 quoted lines
> On 7/6/2010 1:27 PM, Avery Pennarun wrote:
>> The primary advantage of grafts is that you can do something easy
>> *right now* and then fix it all up later.  eg. if you screw up your
>> history extraction and do it better later, you can just re-graft it
>> and you're done.
>
> How does one screw up the history extraction, if one is not doing any
> fancy history rewriting (in this scenario)? Be there dragons?

Well, "rewriting history" necessarily involves changing things about the permanent record. Every time you change things, you have a potential to change them incorrectly. So in general, not rewriting is less error-prone than rewriting :)

Specifically, with a tool like git-subtree, it only really works if a particular subproject has always existed in the same subdir of your repo since it started. If the subdir was ever renamed, or if some of the files were previously part of one subdir but then moved around, git-subtree doesn't (currently) know how to deal with that. git-filter-branch can do anything you want, but you have to teach it how, which is obviously even *more* error prone.

Things are also a little messy if you have some kind of top-level directory with build infrastructure shared by all the subdirs. Does the top-level Makefile have a list of the subdirs it needs to build? If so, there's no way to extract only a subset of true history that will still build correctly - it'll be looking for directories that you explicitly removed. You could update the Makefiles programmatically in every single revision, but that's starting to get extremely messy... and your history stops representing what *real life* really looked like at the time.

If your subdirs haven't been moving around (which sounds like that might be the case for you), and you don't have any top-level files that you care about, rewriting might turn out to be straightforward. You could also make the decision on a subdir-by-subdir basis, I guess.

Have fun,
Avery
Previous: Eric NieblerNext: Eric Niebler
Message 13 of 19 in “help moving boost.org to git”
  1. Eric NieblerJul 5, 2010
  2. Erik Faye-LundJul 5, 2010
  3. Johannes SixtJul 5, 2010
  4. Eric NieblerJul 5, 2010
  5. Sverre RabbelierJul 5, 2010
  6. Raja R HarinathJul 6, 2010
  7. Finn Arne GangstadJul 5, 2010
  8. Eric NieblerJul 5, 2010
  9. Avery PennarunJul 5, 2010
  10. Eric NieblerJul 6, 2010
  11. Avery PennarunJul 6, 2010
  12. Eric NieblerJul 6, 2010
  13. Avery PennarunJul 6, 2010
  14. Eric NieblerJul 6, 2010
  15. Dave AbrahamsJul 6, 2010
  16. Jakub NarebskiJul 6, 2010
  17. David AbrahamsJul 6, 2010
  18. Greg TroxelJul 6, 2010
  19. Eric NieblerJul 6, 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.