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

RE: how do I merge completely unrelated repositories ?

From
KHKelly F. Hickel <kfh@mqsoftware.com>
Date
Jun 26, 2008, 18:42 UTC
Message-ID
<63BEA5E623E09F4D92233FB12A9F794302389CAA@emailmn.mqsoftware.com>
In-Reply-To
<20080626161941.GX20723@cs-wsok.swansea.ac.uk>
Show 49 quoted lines
> -----Original Message-----
> From: git-owner@vger.kernel.org [mailto:git-owner@vger.kernel.org] On
> Behalf Of Oliver Kullmann
> Sent: Thursday, June 26, 2008 11:20 AM
> To: git@vger.kernel.org
> Subject: Re: how do I merge completely unrelated repositories ?
> 
> Hi,
> 
> since a similar question burdens my soul for quite some
> time, I would like to take the opportunity to extend
> the question a bit:
> 
> I have around 10 CVS repositories, each with around 5 modules.
> This has developed over time, and now I want to combine them
> all into a single Git repository, with a new directory
> structure introduced.
> 
> One possibility would be to convert these 50 CVS modules
> into git repositories, then for each of these git repositories
> introduce the new tree structure (that is, what is relevant
> for this part), move all files to their new location (via
> "git mv"), and finally pull everything in into the common
> repository.
> 
> This is all fine, except of the inability to follow the history
> nicely (for example, via gitk I will only see the history
> from the point on where in those temporary git-repositories
> the files have been moved to their new place).
> 
> To avoid this break in the history, it would be great if
> cvsimport could already move the files to the right place
> in the directory hierarchy, that is, if an additional
> parameter P could be given, the initial path, and files
> will be imported as P/file. Then I could import everything right away
> into
> the final git repository, without problems with clashes.
> I can't find something like that in the documentation.
> 
> Is there perhaps some other possibility?
> It seems easiest to me to do this little bit of surgery
> at the time of the import, before git gets into his
> troubles with hash-values.
> 
> thanks!
> 
> Oliver
> 
> 
Oliver,
  I wrote a little (314 line) perl script to blend multiple cvsps output
streams together before handing them to git-cvsimport, it seems to work
fine.  It should (but I haven't tested it) even still allow the
incremental approach.

Not sure if I should just attach it here (it's not that big, but still), but if you need/want a copy of "cvsps_blender.pl", just send me an email and I'll send it out....

-Kelly
Previous: Asheesh LaroiaNext: Jakub Narebski
Message 8 of 9 in “how do I merge completely unrelated repositories ?”
  1. Christian MICHONJun 26, 2008
  2. Miklos VajnaJun 26, 2008
  3. Christian MICHONJun 26, 2008
  4. Johannes SchindelinJun 26, 2008
  5. Miklos VajnaJun 26, 2008
  6. Oliver KullmannJun 26, 2008
  7. Asheesh LaroiaJun 26, 2008
  8. Kelly F. HickelJun 26, 2008
  9. Jakub NarebskiJun 26, 2008

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.