Does anyone know if it's possible to set Detekt threshold in gradle file and keep the configuration in .yml?
Use case: I have three projects in one repo and I want to share the config, but the threshold for each project is independent.
g
gammax
10/15/2020, 6:22 AM
I think you should be able to achieve this by merging different config files (and control which file to pick via Gradle).
And I agree with @gammax, merging configs is the way to do it right now.
f
fo2rist
10/15/2020, 1:33 PM
Thanks, folks!
Yes the issue is exactly what I need, but seems like so far I have to do file manipulations to achieve the similar result.
t
taso
10/26/2020, 1:57 PM
self-plug: There is this plug-in you can use that handles the thresholds for you. It's pretty easy to setup the thresholds per module. You can even have custom logic to evaluate if you want to fail the build or not. https://github.com/GradleUp/static-analysis-plugin/