Get Started

SubGit for Bitbucket

Bitbucket Server How-To

1. Import Subversion repository

In this chapter the one-time import process is described.

1.1 Create Git repository

SVN Mirror Add-on is not involved in those few very first steps. Just create a project if you don’t have one yet.

Now you need to enter your new project and create an empty Git repository there. You can also use an existing repository, conflicts would be available for manual resolving.

SVN Mirror Add-on for Atlassian Bitbucket Server

Give a name to your repository and click Create Repository button. SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.2 Go to Subversion Mirror settings

When you are on an empty repository page, click Actions button in the upper left corner. SVN Mirror Add-on for Atlassian Bitbucket Server

By clicking on the button you will get to the Subversion Mirror page. SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.3 Specify the details

Specify Subversion URL: SVN Mirror Add-on for Atlassian Bitbucket Server

You can specify Subversion credentials as username/password, SSH private key or SSL client certificate. Add-on might also use Subversion authentication cache.

SVN Mirror Add-on for Atlassian Bitbucket Server

Choose your way of dealing with branches and tags translation. You may configure it manually, you may not bother if all you have is a single directory. SVN Mirror Add-on for Atlassian Bitbucket Server

You could also try doing it automatically - you’ll need to specify the ‘trunk’ directory, that is the main branch directory in the SVN repository, e.g. ‘trunk’, ‘develop’ or ‘branches/main’. Add-on will explore the history of this branch and find all other branches automatically. Keep in mind, this process might take a while. SVN Mirror Add-on for Atlassian Bitbucket Server

Specify the default e-mail domain for authors mapping. It would be used for the SVN authors which don’t have any match in local and global authors mapping configuration. SVN Mirror Add-on for Atlassian Bitbucket Server

And press Continue

up

1.4 Branch mapping

If additional branch mapping is needed you may easily specify it on the first tab with an example of mapping provided. SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.5 Adjust translation settings

There are four options of how authors mapping will be going on.

At first, you could specify matches manually at Authors Mapping tab. If this wouldn’t be present or there should be no match, add-on will try to find Git authors using SVN username among registered users. If that wouldn’t be the case, global authors mapping scheme is to be used. You can also change your default e-mail domain here.

SVN Mirror Add-on for Atlassian Bitbucket Server

By following the global authors mapping link you’ll get to the Global Subversion Mirror Settings. Here in the similiar text field you can specify global authors mapping settings which would work for all of your repositories.

SVN Mirror Add-on for Atlassian Bitbucket Server

Find more details on authors mapping and SVN credentials processing at dedicated documentation page.

Translation settings could be set if you ran the import at least for one time. You can specify the start revision and decide if you need to track changes in .gitattributes or .gitignore files.

SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.6 Adjust authors mapping

Here you can describe your custom mapping with an example in the field provided. Don’t forget to turn it on by setting the Use Repository Authors Mapping option on (it will be enabled by default, just make sure it’s still there).

SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.7 Adjust connection settings

Here you can change the SVN URL, or add and change credentials you would like to use. You can also set the interval for polling Subversion for some changes. Set to zero it would say to the system to wait for your request. SVN Mirror Add-on for Atlassian Bitbucket Server

up

1.8 Start import

Finally, click Import button. The progress bar will start. Import process may take a while depending on the size of SVN repository and your connection to SVN server. SVN Mirror updates header as soon as import is done. Now you have Git repository with contents of specified Subversion repository and you can use it as a regular Git repository.

SVN Mirror Add-on for Atlassian Bitbucket Server

After the import is done you can turn you imported repository into the mirror anytime by simply clicking the Enable button. SVN Mirror Add-on for Atlassian Bitbucket Server

up

Prerequisites: Using this manual you would be able to create a mirror or to make an one-time import for your SVN project. You should be Repository Administrator in order to mirror SVN repository to Git.

2. Mirror Subversion repository

This chapter is dedicated to the mirroring feature of SVN Mirror Add-on.

2.1 Create Git repository

SVN Mirror Add-on is not involved in those few very first steps. Just create a project if you don’t have one yet.

Now you need to enter our new project and create an empty Git repository there. You can also use an existing repository, conflicts would be available for manual resloving.

SVN Mirror Add-on for Atlassian Bitbucket Server

Give a name to your repository and click Create Repository button. SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.2 Go to Subversion Mirror settings

When you are on an empty repository page, click Actions button in the upper left corner. SVN Mirror Add-on for Atlassian Bitbucket Server

By clicking on the button you will get to the Subversion Mirror page. SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.3 Specify the details

Specify Subversion URL: SVN Mirror Add-on for Atlassian Bitbucket Server

You can specify Subversion credentials as username/password, SSH private key or SSL client certificate. Add-on might also use Subversion authentication cache.

SVN Mirror Add-on for Atlassian Bitbucket Server

Choose your way of dealing with branches and tags translation. You may configure it manually, you may not bother if all you have is a single directory. SVN Mirror Add-on for Atlassian Bitbucket Server

You could also try doing it automatically - you’ll need to specify the ‘trunk’ directory, that is the main branch directory in the SVN repository, e.g. ‘trunk’, ‘develop’ or ‘branches/main’. Add-on will explore the history of this branch and find all other branches automatically. Keep in mind, this process might take a while. SVN Mirror Add-on for Atlassian Bitbucket Server

Specify the default e-mail domain for authors mapping. It would be used for the SVN authors which don’t have match in local and global authors mapping configuration. SVN Mirror Add-on for Atlassian Bitbucket Server

And press Continue

up

2.4 Branch mapping

If additional branch mapping is needed you may easily specify it on the first tab with an example of mapping provided. SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.5 Adjust translation settings

There are four options of how authors mapping will be going on.

At first, you could specify matches manually at Authors Mapping tab. If this wouldn’t be present or there should be no match, add-on will try to find Git authors using SVN username among registered users. If that wouldn’t be the case, global authors mapping scheme is to be used. You can also change your default e-mail domain here.

SVN Mirror Add-on for Atlassian Bitbucket Server

By following the global authors mapping link you’ll get to the Global Subversion Mirror Settings. Here in the similiar text field you can specify global authors mapping settings which would work for all of your repositories.

SVN Mirror Add-on for Atlassian Bitbucket Server

Find more details on authors mapping and SVN credentials processing at dedicated documentation page.

Translation settings could be set if you ran the import at least for one time. You can specify the start revision and decide if you need to track changes in .gitattributes or .gitignore files.

SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.6 Adjust authors mapping

Here you can describe your custom mapping with an example in the field provided. Don’t forget to turn it on by setting the Use Repository Authors Mapping option on (it will be enabled by default, just make sure it’s still there).

SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.7 Adjust connection settings

Here you can change the SVN URL, or add and change credentials you would like to use. You can also set the interval for polling Subversion for some changes. Set to zero it would say to the system to wait for your request. SVN Mirror Add-on for Atlassian Bitbucket Server

up

2.8 Enable Mirror

Finally, click Mirror button to enable the mirror. The progress bar will start. Initial import process may take a while depending on the size of SVN repository and your connection to SVN server.

SVN Mirror updates header as soon as import is done. Now you have Git repository synchronized with specified Subversion repository and you can use it as a regular Git repository. You will see changes committed to SVN in your Git repository and vice versa.

SVN Mirror Add-on for Atlassian Bitbucket Server

After synchronisation is finished, mirroring is turned on. You can switch it off and turn it on again any time you want. Commits pushed to Git while the mirror was switched off would be marked as unsynced and would be presented on the related tab.

You can change configuration, connection settings, authors mapping any time you want.

up

2.9 Unsynced commits

In case your Git repository was not completely empty before initial import started, you’ll get new tab where you could resolve occured commit conflicts. SVN Mirror Add-on for Atlassian Bitbucket Server

up

3. Rest API

SVN Mirror Add-On for Bitbucker Server provides a number of REST API end points that could be used to control configured mirrors. For more details, please see the related article.

up

Contact us

Please fill out all fields.


By clicking on this button you agree to provide us your personal data for the purpose of technical support for you. Please read our Privacy policy for more details.

Thank you for contacting us!
We will get back to you soon.

We are sorry, something went wrong. Please try again or contact us.