Build: Pull "skip assemble on qa" to common build (#35214)

Pull all of the logic that we use to skip the `assemble` and
`dependenciesInfo` tasks on `qa` projects into one spot in our root
build file.
This commit is contained in:
Nik Everett 2018-11-05 16:16:00 -05:00 committed by GitHub
parent 216c761a5d
commit f72ef9b5fd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 5 additions and 87 deletions

View File

@ -555,11 +555,13 @@ wrapper {
}
}
/* Remove assemble/dependenciesInfo on all qa projects because we don't need to publish
* artifacts for them. */
gradle.projectsEvaluated {
subprojects {
if (project.path.startsWith(':qa')) {
/*
* Remove assemble/dependenciesInfo on all qa projects because we don't
* need to publish artifacts for them.
*/
if (project.name.equals('qa') || project.path.contains(':qa:')) {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false

View File

@ -15,14 +15,3 @@ subprojects {
}
}
}
/* Remove assemble on all qa projects because we don't need to publish
* artifacts for them. */
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
}
}

View File

@ -15,16 +15,3 @@ subprojects {
}
}
}
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
Task dependenciesInfo = project.tasks.findByName('dependenciesInfo')
if (dependenciesInfo) {
dependenciesInfo.enabled = false
}
}
}

View File

@ -27,18 +27,6 @@ gradle.projectsEvaluated {
.each { check.dependsOn it.check }
}
/* Remove assemble on all qa projects because we don't need to publish
* artifacts for them. */
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
}
}
integTest.enabled = false
run {

View File

@ -16,16 +16,5 @@ subprojects {
}
}
/* Remove assemble on all qa projects because we don't need to publish
* artifacts for them. */
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
}
}
// the qa modules does not have any source files
licenseHeaders.enabled = false

View File

@ -15,16 +15,3 @@ subprojects {
}
}
}
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
Task dependenciesInfo = project.tasks.findByName('dependenciesInfo')
if (dependenciesInfo) {
dependenciesInfo.enabled = false
}
}
}

View File

@ -125,13 +125,4 @@ subprojects {
setting 'script.max_compilations_rate', '1000/1m'
}
}
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
Task dependenciesInfo = project.tasks.findByName('dependenciesInfo')
if (dependenciesInfo) {
dependenciesInfo.enabled = false
}
}

View File

@ -18,18 +18,3 @@ subprojects {
}
}
}
/* Remove assemble on all qa projects because we don't need to publish
* artifacts for them. */
gradle.projectsEvaluated {
subprojects {
Task assemble = project.tasks.findByName('assemble')
if (assemble) {
assemble.enabled = false
}
Task dependenciesInfo = project.tasks.findByName('dependenciesInfo')
if (dependenciesInfo) {
dependenciesInfo.enabled = false
}
}
}