is chapter '36.2.3.1. Filtering by name' in the documentation what you are looking for?
namely:
configure(subprojects.findAll {it.name != 'PROJECT_X' && it.name !=
'PROJECT_Y'}) {
apply plugin: 'java'
}
Haven't tried it but sounds like what you want?
regard
gretar
