Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Exclude a package root from SonarLint?

How do you exclude all classes in a particular root package in SonarLint?

For example, I want to exclude all classes such as foo.bar.xxx and foo.bar.yyy.zzz.

I've tried both of these no to avail:

  • sonar.exclusions = /foo/bar/**
  • sonar.exclusions = **/foo/bar/**

I'm using the Intellij plugin, but I assume that the syntax would follow the same documented one from here (https://docs.sonarqube.org/display/SONAR/Narrowing+the+Focus)

like image 797
steve cook Avatar asked Apr 07 '26 22:04

steve cook


1 Answers

Unfortunately the sonar.exclusions property is ignored by SonarLint for IntelliJ (and Eclipse too). There's a ticket to add support for that, feel free to vote on it:

https://jira.sonarsource.com/browse/SLI-97

like image 189
janos Avatar answered Apr 10 '26 11:04

janos