sonar-swift
sonar-swift copied to clipboard
Need configuration of File Suffixes
Most plugins allow you to modify file suffixes so you can prevent conflicts with other analyzers. Our Sonarqube server is also used to scan c/c++ projects and the objective-c portion of this plugin causes a conflict with .h files. It would be great if this feature would be added so that file extensions could be configured.
Can you provide an example of such plugins?
C++ community plugin (https://github.com/SonarOpenCommunity/sonar-cxx) provides this and other options as a tab under Administration --> General Settings --> C++ (Community). For languages directly provided/support by Sonarqube, File Suffixes is present as an option under Administration --> General Settings --> Languages -->
Hello. I got absolutely same situation here, using C++ community plugin and this swift\objC plugin:
ERROR: Language of file 'main/jcPKCS11f.h' can not be decided as the file matches patterns of both sonar.lang.patterns.c++ : **/*.cxx,**/*.cpp,**/*.cc,**/*.c,**/*.hxx,**/*.hpp,**/*.hh,**/*.h and sonar.lang.patterns.objc : **/*.h,**/*.m,**/*.mm
Is there any chance, that file suffixes options will be added for this plugin?
My solution is to add parameter to filter one of the patterns, like:
-Dsonar.lang.patterns.objc=-