3

I've been working on a project, using Bazaar as a version control system. Now I have to work with people offshore, and they only want to use SVN.

What I have:

  • My bazaar branch with its files and revisions.
  • A brand new subversion repository.

What I want:

  • My bazaar branch with its files and revisions.
  • The subversion repo with the same files and revisions (includings dates and commit messages).
  • Being able to pull / push from/to the SVN using bzr.

I managed to copy the branch into the svn repo using tailor, but bazaar won't recognized it (Branches have no common ancestor).

Is such a thing possible?

jelmer
  • 2,405
  • 14
  • 27
ZeWaren
  • 3,978
  • 2
  • 20
  • 21

1 Answers1

4

Yes, this is possible using bzr-svn. After you've created your Subversion repository, simply push to trunk:

$ svnadmin create /my/svn/repo
$ cd /my/bzr/branch
$ bzr push /my/svn/repo/trunk
Pushed up to revision X.

After that, you should be able to pull from the trunk whenever they have made changes. You can push your changes using bzr push, possibly after rebasing them if the branches have diverged (using bzr rebase in the bzr-rewrite plugin).

SamB
  • 9,039
  • 5
  • 49
  • 56
jelmer
  • 2,405
  • 14
  • 27
  • Yes, bzr-svn is definitely the way to go! I personally wouldn't go the rebase route though: if you rebase *one* branch, you'll probably need to rebase a bunch of other branches. Instead, I would just make a branch of the SVN trunk and `bzr merge` your changes into that, then `bzr push` back to SVN. (If jelmer tells you that won't work, though, he's probably right: he *is* the author of bzr-svn, after all!) – SamB Mar 14 '11 at 19:01
  • This worked for me when I added "--overwrite" key (otherwise I was being reported about "diverged" branches). – Yury May 04 '12 at 13:03