sonar-detekt
sonar-detekt copied to clipboard
Detekt config outside of the project
Hello,
We share our single detekt config file via one of our gradle plugin used for all our projects. The file is then not available in each project structure but in one of their build dependency. Would it be possible to provide this config file through the sonar-kotlin plugin admin ?
Thanks for your help.
Hello,
Can you please elaborate on what are you trying to achieve?
As shown in the linked image, you can specify the detekt config yaml file.
What does prevent you to specify the detekt config yaml file here?
Hi @schalkms, the detekt config file resides in a shared gradle library. It is then not available in the project file tree. Because we only use one config for all of our projects, if it was possible to define it in the admin, it would works for our setup.
Thanks.
It is then not available in the project file tree.
But the detekt config file in your shared Gradle library is available on the file system, as far as I understand your use case. Do you know where the config file in your Gradle library resides in order to reference the config file directly? What prevents you from copying this file in your project tree via a Gradle command if you can't reference the detekt config file in your Gradle library?