subprojects { proj -> proj.afterEvaluate { // Used to generate initial maven-dir layout task "create-dirs" { description = "Create default maven directory structure" } << { sourceSets*.java.srcDirs*.each { it.mkdirs() } sourceSets*.resources.srcDirs*.each { it.mkdirs() } } } }