Re: connecting existing local git repository to svn

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





Sverre Rabbelier wrote:

On Tue, Jan 27, 2009 at 11:41, Ittay Dror <ittay.dror@xxxxxxxxx> wrote:
git: ----v1----v2----v3--v4---v5
svn:                     \---v4--v5

so the svn history starts from v3, but the git history remains unchanged.

Create the new branch from v3 then, and use git svn to pull it in.
Then you can do 'git rebase that-svn-branch' on your git branch to put
all commits (not as one big commit) on top of that branch point. Now
you 'git checkout' that-svn-branch and do 'git reset --hard
the-git-branch', which should now consist of
v1--v2--v3--v4(git)--v5(git), etc. If you do 'git svn dcommit' from
the that-svn-branch now it should dcommit to svn each of your git
sorry, my ascii art was confusing:

git: ----v1----v2----v3--v4---v5
svn: v1-4---v5

v1-4 is v1 to v4 squashed together. (e.g., if i added a file in v2 and removed in v3 it will not appear in svn history)

hope it is clear now.

ittay
commits individually. Of course, don't forget to make a backup before
you start messing around :P.


--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux