hmvictor / radar-netbeans

A SonarQube plugin for Netbeans
Other
33 stars 22 forks source link

Feature request: Support for scan a single file #73

Open luiscla27 opened 5 years ago

luiscla27 commented 5 years ago

Please add support to scan a single file, the old sonar-runner would implementation would look like this:

sonar-runner -Dsonar.inclusions=src/main/java/com/foo/MyClass.java

However there should be a way to do the same using the brand new sonnar scanner maybe the sonar.working.directory parameter would do the trick, the documentation says this:

sonar.working.directory Set the working directory for an analysis triggered with the SonarScanner or the SonarScanner for Ant (versions greater than 2.0). This property is not compatible with the SonarScanner for MSBuild. Path must be relative, and unique for each project.  Beware: the specified folder is deleted before each analysis. .sonar

Also maybe the narrowing focus section explains some exclusion/inclusions that may help.

The expected UI should look somethign like this: image