I have a previously working SVN-Mirror using the default mapping which maps TRUNK to master. On the svn side branches are not used and on the git side branches are used for development lifecycle management (i.e. develop->release->master<->hotfix). It's not likely the svn project is going to restructure their repository. How can I at lease change the mapping to be svn.TRUNK<->git.develop? I would like to keep development commits off of the master branch since we use that for production commits.
It is impossible to change branch mappings for established Git-SVN mirror, so you have to start with an empty Git repository and re-import your Subversion repository with proper settings.
Please specify the following values in order to map 'trunk' to 'develop' branch in Git repository:
url = <SVN_URL>
trunk = trunk:refs/heads/develop
branches = branches/*:refs/heads/*
shelves = shelves/*:refs/shelves/*
tags = tags/*:refs/tags/*
Note that you can map certain branches explicitly, e.g.:
branches = branches/stable:refs/heads/master; branches/*:refs/heads/*
Another thing I'd like to mention is that although you don't use branches on Subversion side, I'd still recommend to keep them synchronized with Git. By design SubGit plugin synchronizes every single branch found in Git repository. If some Git branch doesn't have configured mapping, then the plugin automatically sends that branch to shelves/<auto_generated_branch_name>. So, it's better to specify all the existing branch mappings to avoid those auto-generated shelf-branches.
Hope that helps,
As a project manager, I have discovered that different developers want to bring their previous branching method with them when they join the team. Some developers are used to performing individual wo...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs