Permission Template Regexp not working


Template for a good bug report:

  • versions used (SonarQube, Scanner, Plugin, and any relevant extension) SonarQube 6.7 (build 33306)

I have 2 templates for projects: first is default one without any regexp
Second one is “SFDC-Local*”

When I am creating new project project Keys are made like this “SFDC-Local:branch-name”
and they are not automatically assinged to second permission template.

May I know why it’s like this?

I have also checked options with ProjectKeys=“Sonar.Local:branch-name” and regexp=“Sonar.Local*” - that was also not working.



You’re using bash regex, not “standard” regex. Try SFDC-Local.*



Hi Maciej,

FYI, a useful tool whenever working with regex:

That allows you to validate your approach, independently of any specific tool (like SonarQube).

If we take your example here, we can see that the regex you mentioned does not yield a full match on the entire project key:

1 Like

Hi there,

You are right!
Sorry I was so used to bash then I forgot to check other options.

Thank you!

1 Like

Hi All
Thank you very much for this hint with the dot. I got the same problem and now it is working


what if I want to apply the same permission template to two different types of projectkey’s.

Ex: and com.sonar.test

Can I use it something like:, com.sonar.test. ( I tried this and it didn’t work for both of them )

Any suggestions?


I think you’d just need to search/apply them serially.