Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Merging changes from Mercurial to Subversion during build

Jan Swaelens
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 15, 2012

Hello,

We are playing with the idea to move our trunk svn to a mercurial repository, but we would still like to maintain our subversion trunk branch.

Since there have been quite some changes in the 'automatic merge' functionality of Bamboo I wanted to ask if this would be possible, without too much 'hassle' (read as: additional work).

Could we configure Bamboo to merge the changes made to the mercurial branch to the svn one when a build is made (triggered by a poll of the mercurial branch)?

thanks!

4 answers

1 accepted

1 vote
Answer accepted
PiotrA
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 15, 2012

That's quite a challenge there. While I'm certain that Bamboo 'out-of-the-box' doesn't do what you need, I believe the proper solution here would be to plug into your central hg repository with a pre-push hook (or how they are called, you know - the hooks that get triggered whenever a new commit is pushed to your central repository in Mercurial) in such a way, that they will try to commit and sync with your svn repository, and if it fail - reject the hg push. That way the automatic merges from Bamboo won't push successfully if the changeset failed to be committed to the svn repo.

Though, I don't know if there is out-of-the-box solution for transforming arbitrary hg commit into svn commit...

0 votes
Jan Swaelens
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 15, 2012

Ah I see, life is never easy :-).

This makes me want to dump the subversion branch altogether even more...

Thanks for the feedback!

0 votes
Jan Swaelens
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 15, 2012

We don't at the moment, we are exploring our options to see how we can do that -- I was hoping that there was some 'out of the box' solution that might work for us. We are just starting to play with the idea, our main goal is to have the flexibility in DEV of DVCS but (at least for now) keep everything else which is ented on the SVN repo 'as is'.

0 votes
PiotrA
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 15, 2012

Hello Jan,

I'd like to know a little bit more about your use-case, so here is my question: if you do a manual merge in your mercurial branch (manually, without Bamboo), are you able to manually 'merge' it into your svn mirror? How do you do that? With some help from hg-svn bridge/extension?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events