Heads up! ScriptRunner for Bitbucket documentation has moved to https://docs.adaptavist.com/sr4bib. Adaptavist will keep this site up for a bit, but no future updates to documentation will be published here. ScriptRunner 6.20.0 will be the last release to link to scriptrunner.adaptavist.com for in-app help.

This page describes how to migrate from Bitbucket Server 6.x to 7.0. Release is the first release that is compatible with Bitbucket Server 7.0 onwards.

If you have any issues please contact us via our Service Desk.

At the time of writing, the official page explaining the upgrade procedure is here which we recommend you read before upgrading.

How to Upgrade

First you should create a clone of your production system that you can do a practice upgrade on. There is an Atlassian knowledge base article about creating a staging system here.

Once you have the staging system created, upgrade it to Bitbucket Server 7. Then install the ScriptRunner plugin.

The static type checker available in ScriptRunner for Bitbucket Server should be able to indicate problems quite quickly.

You should open each admin page that lists each extension point, eg pre-receive hooks, event handlers etc. Look for code highlighted with red errors, fix them and check that the script shows the green dot of successful compilation.

green dot


If practical, test your most important scripts and conditions in your staging server.

Production Upgrade

Finally, make sure that your maintenance window includes enough time to do your production upgrade, and then the modifications to the scripts that you have already tested in your staging server.

Have questions? Visit the Atlassian Community to connect, share, and learn with other Atlassian users and experts, including Adaptavist staff.

Ask a question about ScriptRunner for JIRA, Bitbucket Server, or Confluence.

Want to learn more? Check out courses on Adaptavist Learn, an online platform to onboard and train new users for Atlassian solutions.