Hi @caraujo84
Just to be clear, to exclude all files and sub-directories under this folder, the setting should be:
sonar.exclusions = src/CommerceApp.Web/_SystemResources/**
Just to be clear by “does not work”, I assume you mean that the files you are trying to exclude from the analysis are still visible when you browse the Code tab of your project on SonarCloud UI. If you mean something else, please clarify!
Since sonar.exclusions = **/**
should indeed exclude everything from sources (do not analyze, and will not show up on Code tab), I suspect we’re missing something.
I think it may be useful to review the effective settings related to the analysis. Please go to Administration / Background Tasks page of your project, pick a task where you tried to apply sonar.exclusions = src/CommerceApp.Web/_SystemResources/**
, and from the dropdown menu at the right, select Show SonarScanner Context, and copy-paste from it the content of “Project server settings” and “Project scanner properties” sections. I’m mainly interested in the sonar.sources
, sonar.exclusions
and sonar.inclusions
settings. If you prefer to share privately, just let me know and I’ll start a private thread. Here’s an example extract:
Project server settings:
- sonar.autoscan.enabled=true
- sonar.exclusions=src/CommerceApp.Web/_SystemResources/**
Project scanner properties:
- sonar.coverage.exclusions=**/*
- sonar.exclusions=**/autopep8.py,**/*.cs,**/*.c,**/*.h,**/*.cc,**/*.cpp,**/*.cxx,**/*.c++,**/*.hh,**/*.hpp,**/*.hxx,**/*.h++,**/*.ipp,**/*.m,**/*.java,**/*.jav,**/*sql,**/*tab,**/*pkb,**/*.vb,src/CommerceApp.Web/_SystemResources/**
- sonar.host.url=https://sonarcloud.io/
- sonar.sources=.
- sonar.test.exclusions=**/*.cs,**/*.c,**/*.h,**/*.cc,**/*.cpp,**/*.cxx,**/*.c++,**/*.hh,**/*.hpp,**/*.hxx,**/*.h++,**/*.ipp,**/*.m,**/*.java,**/*.jav,**/*sql,**/*tab,**/*pkb,**/*.vb