* Breaking up repositories
@ 2007-05-31 6:50 Jason Sewall
2007-05-31 13:55 ` Dave Hanson
0 siblings, 1 reply; 5+ messages in thread
From: Jason Sewall @ 2007-05-31 6:50 UTC (permalink / raw)
To: git
I recently imported my subversion repo with git-svn and I'm curious
what the best way to break up the monolithic repo (my many disparate
projects from my single svn repo) into individual git repos of their
own.
I'm still trying to get a grasp on the considerable git toolbox and I
can't seem to find the functionality I'm describing, but I'm sure it
exists - I heard Linus talk about it in that Google talk on git!
Thanks,
Jason
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Breaking up repositories
2007-05-31 6:50 Jason Sewall
@ 2007-05-31 13:55 ` Dave Hanson
0 siblings, 0 replies; 5+ messages in thread
From: Dave Hanson @ 2007-05-31 13:55 UTC (permalink / raw)
To: Jason Sewall; +Cc: git
I had similar problem; I split my monolithic repo, monolithic-git, as follows.
1. When I did the git-svn, I ended up with git branches for each
project in my svn repo. I think I created these by hand, but I don't
recall.
2. To split project foo into its own repo, foo-git, from monolithic-git, I did:
mkdir foo-git
cd foo-git
git init
git pull ../monolithic-git foo
>From then on, I worked in foo-git. Eventually, I pitched
monolithic-git. I suspect there's a better way to do this...others
will surely chime in.
dave h
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Breaking up repositories
@ 2007-05-31 15:53 Josh Triplett
2007-06-01 7:45 ` Andy Parkins
2007-06-01 10:25 ` Jakub Narebski
0 siblings, 2 replies; 5+ messages in thread
From: Josh Triplett @ 2007-05-31 15:53 UTC (permalink / raw)
To: Jason Sewall; +Cc: git, Jamey Sharp
[-- Attachment #1: Type: text/plain, Size: 1298 bytes --]
Jason Sewall wrote:
> I recently imported my subversion repo with git-svn and I'm curious
> what the best way to break up the monolithic repo (my many disparate
> projects from my single svn repo) into individual git repos of their
> own.
>
> I'm still trying to get a grasp on the considerable git toolbox and I
> can't seem to find the functionality I'm describing, but I'm sure it
> exists - I heard Linus talk about it in that Google talk on git!
In the specific case of git-svn, you can probably give git-svn the
appropriate paths to import each project separately; that may do what you
want, depending on your repository layout.
In the general case, if you want to split a subtree of a git repo into a git
repo, you want git-split, by Jamey Sharp and I:
<http://people.freedesktop.org/~jamey/git-split>
From a copy of the git repo you want to split, just run "git-split subdir",
optionally with a newest and oldest commit, and it will output the sha1 of
the new top commit for use as the new branch ref. Remove all other
branches, reflogs, and other references to the old commits, and use prune
or gc to get rid of old objects. Repeat as desired for other subdirs.
We really need to fix some things in git-split and get it merged into git.
- Josh Triplett
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 252 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Breaking up repositories
2007-05-31 15:53 Breaking up repositories Josh Triplett
@ 2007-06-01 7:45 ` Andy Parkins
2007-06-01 10:25 ` Jakub Narebski
1 sibling, 0 replies; 5+ messages in thread
From: Andy Parkins @ 2007-06-01 7:45 UTC (permalink / raw)
To: git; +Cc: Josh Triplett, Jason Sewall, Jamey Sharp
On Thursday 2007 May 31, Josh Triplett wrote:
> We really need to fix some things in git-split and get it merged into git.
Obviously it's Junio's call, but can I suggest that getting it in the git tree
(presumably under contrib/) should not be dependent on fixing
whatever "things" you are worrying about? Waiting until it's perfect before
submitting it. As Voltaire said (I think), "better is the enemy of good".
Speaking from my own personal viewpoint, while I'm not a huge contributor to
git, I do fix the odd buglet here and there - and here's the rub - I only do
it to those files that are in the git tree.
While git-split is being maintained separately, I would argue that there are
less eyes on it. Get it in, regardless of state, at the very least it will
mean that git-split's development will be tracked as publicly as git.
Andy
--
Dr Andy Parkins, M Eng (hons), MIET
andyparkins@gmail.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Breaking up repositories
2007-05-31 15:53 Breaking up repositories Josh Triplett
2007-06-01 7:45 ` Andy Parkins
@ 2007-06-01 10:25 ` Jakub Narebski
1 sibling, 0 replies; 5+ messages in thread
From: Jakub Narebski @ 2007-06-01 10:25 UTC (permalink / raw)
To: git
Josh Triplett wrote:
> Jason Sewall wrote:
>> I recently imported my subversion repo with git-svn and I'm curious
>> what the best way to break up the monolithic repo (my many disparate
>> projects from my single svn repo) into individual git repos of their
>> own.
>
> In the specific case of git-svn, you can probably give git-svn the
> appropriate paths to import each project separately; that may do what you
> want, depending on your repository layout.
>
> In the general case, if you want to split a subtree of a git repo into a git
> repo, you want git-split, by Jamey Sharp and I:
> <http://people.freedesktop.org/~jamey/git-split>
> From a copy of the git repo you want to split, just run "git-split subdir",
> optionally with a newest and oldest commit, and it will output the sha1 of
> the new top commit for use as the new branch ref. Remove all other
> branches, reflogs, and other references to the old commits, and use prune
> or gc to get rid of old objects. Repeat as desired for other subdirs.
I have added info about git-split to Git Wiki
http://git.or.cz/gitwiki/InterfacesFrontendsAndTools
Please improve this information, and correct if it is wrong.
--
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-06-01 10:20 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-31 15:53 Breaking up repositories Josh Triplett
2007-06-01 7:45 ` Andy Parkins
2007-06-01 10:25 ` Jakub Narebski
-- strict thread matches above, loose matches on Subject: below --
2007-05-31 6:50 Jason Sewall
2007-05-31 13:55 ` Dave Hanson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).