How to update sonarqube master branch without losing analysis history?

  • which versions are you using
    SonarQube version: (Developer Edition)

  • what are you trying to achieve
    Change the Sonarqube analytics master branch.

  • what have you tried so far to achieve this
    Rename the branch name for develop.


The issue is that I submitted the develop branch for analysis by sonarqube, so it is currently identifying two branches: master and develop.

Because of this I can’t change the name for the develop branch.
But if I delete the develop branch I lose all its analysis history, right? This history is very important.

How can I change sonarqube’s main branch to develop without losing the analysis history of that branch?

Hey there.

Today, there’s no way to non-destructively change the main branch to another branch. We hope to have a solution for v9.5, and I welcome you to add your vote on our roadmap.

1 Like

Hey Colin, everything all right?

So, I’ll be waiting and hoping that this option really comes in the next version.