newCode.referenceBranch to be used with git tag

I’ve a question regarding usage of sonar-scanner (sonar-scanner-cli-5.0.1.3006-linux) with SonarQube Enterprise Edition 10.1.

We are using flag

-sonar.newCode.referenceBranch

In order to have valid comparison of new code with a branch which was already scanned.
Problem is that this flag is looking for specified branch in SCM, and it’s doing it only for branches →

00:13:46 WARN: Could not find ref ‘smf-12.5.0.5’ in refs/heads, refs/remotes, refs/remotes/upstream or refs/remotes/origin

and in our project we are mostly working with tags →

git ls-remote | grep 12.5.0.5
3456783b7ed47dd1f9ce2d9c8823eaded436d8a7 **refs/tags/**smf-12.5.0.5

Do You know if there is some way to “force” above flag to look for specified value also under “refs/tags” ?

Of course above tag (smf-12.5.0.5) is already scanned in my project but still comparison can’t be done cause it can be find by sonar-scanner in SCM…

Hi,

Sorry, but there’s no way to make it look for tags.

 
Ann