https://kotlinlang.org logo
#detekt
Title
# detekt
z

zmoore

03/19/2020, 10:17 PM
Is it currently possible to extend a config that is not the base config? Would this be something we would be interested in in the library?
s

schalkms

03/20/2020, 8:28 PM
Do you know about the
buildUponDefaultConfig = true
config option? If I understand you correctly, it's exactly what you need.
a

Artur Bosch

03/21/2020, 10:39 AM
The
config
property/flag supports comma separated
config
paths e.g.
"${rootProject.resolve('top-config')},${project.resolve('relative-path-config')}"
. Isn't this exactly what you want? The top level project config is the general config and the module config's are merged on the base config.
c

chao

03/22/2020, 6:25 AM
That’s interesting. I was wondering if I should customize our own plugin to merge config files, but it does exist today.
Thanks @schalkms @Artur Bosch for the information. This is very close to what we want.
(I have to confess that we have a custom gradle plugin to run
Detekt
Task, so I would need to port the code and test if our custom gradle plugin that handles this case
a

Artur Bosch

03/22/2020, 9:21 AM
It's the cli flag
config
which handles this case. So your gradle plugin should also be able to use it 😉. What are your additional use cases so you need a custom gradle plugin?
c

chao

03/24/2020, 5:38 PM
We found it hard to process
AndroidSourceSet
where we would like one gradle task per
AndroidSourceSet
z

zmoore

03/24/2020, 5:40 PM
We also merge checkstyle reports from all our tasks into a single one