I have a multi project scenario, my root project contains something like this inside build.gradle:
subprojects{
task myTask {
… do something
}
}
I have then several sub projects (:a,:b,:c,:d). Some of these apply the war plugin using:
plugins {
id ‘war’
}
Inside one of the subprojects( :b) that also applies the plugin ‘war’ I want obtain some informations about the other subprojects. I want to create list of all suproject that have a task (i.e ‘war’) available. I have tried the following in build.gradle of sub project :b without success:
Thanks, that indeed can give me the list at it’s ok too to base it on the plug-in presence. But I need to do it at configuration time and when I try just the following in the build.gradle of a subproject:
it only return the subprojects already configured, not those still to be configured.
I basically need to tell that the task “X” that is present in most subprojects, should run last in project “last” as long as this project is included in the build.