mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 12:51:06 +00:00
Bug 1384680 - Generalize GRADLE_MAVEN_REPOSITORY to GRADLE_MAVEN_REPOSITORIES. r=gps,sebastian
I'm confident nobody is configuring this locally, so there's no reason to keep the existing name (and grow the new semantics) nor to deprecate the existing name explicitly. MozReview-Commit-ID: HW3epgwZFpO --HG-- extra : rebase_source : d328f9ce9299dcd80e508925314236747aee1ea3
This commit is contained in:
parent
ac68bff32b
commit
4bbca312cf
@ -30,9 +30,9 @@ allprojects {
|
||||
}
|
||||
|
||||
repositories {
|
||||
if (gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORY) {
|
||||
gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORIES.each { repository ->
|
||||
maven {
|
||||
url gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORY
|
||||
url repository
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -42,9 +42,9 @@ buildDir "${topobjdir}/gradle/build"
|
||||
|
||||
buildscript {
|
||||
repositories {
|
||||
if (gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORY) {
|
||||
gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORIES.each { repository ->
|
||||
maven {
|
||||
url gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORY
|
||||
url repository
|
||||
}
|
||||
}
|
||||
// For android-sdk-manager SNAPSHOT releases.
|
||||
|
@ -14,7 +14,7 @@ NO_NDK=1
|
||||
. "$topsrcdir/mobile/android/config/mozconfigs/common"
|
||||
|
||||
ac_add_options --with-gradle="$topsrcdir/gradle-dist/bin/gradle"
|
||||
export GRADLE_MAVEN_REPOSITORY="file://$topsrcdir/jcentral"
|
||||
export GRADLE_MAVEN_REPOSITORIES="file://$topsrcdir/jcentral"
|
||||
|
||||
unset HOST_CC
|
||||
unset HOST_CXX
|
||||
|
@ -15,8 +15,8 @@ NO_NDK=1
|
||||
|
||||
# We want to download Gradle.
|
||||
ac_add_options --with-gradle
|
||||
# We want to use (and populate!) the local Nexus repository.
|
||||
export GRADLE_MAVEN_REPOSITORY="http://localhost:8081/nexus/content/repositories/jcenter/"
|
||||
# We want to use (and populate!) the local Nexus repositories.
|
||||
export GRADLE_MAVEN_REPOSITORIES="http://localhost:8081/nexus/content/repositories/jcenter/"
|
||||
|
||||
# From here on, just like ../android-api-15-frontend/nightly.
|
||||
|
||||
|
@ -3,6 +3,6 @@
|
||||
. "$topsrcdir/mobile/android/config/mozconfigs/android-api-15/nightly"
|
||||
|
||||
ac_add_options --with-gradle="$topsrcdir/gradle-dist/bin/gradle"
|
||||
export GRADLE_MAVEN_REPOSITORY="file://$topsrcdir/jcentral"
|
||||
export GRADLE_MAVEN_REPOSITORIES="file://$topsrcdir/jcentral"
|
||||
|
||||
. "$topsrcdir/mobile/android/config/mozconfigs/common.override"
|
||||
|
@ -45,15 +45,22 @@ def gradle_flags(value):
|
||||
|
||||
set_config('GRADLE_FLAGS', gradle_flags)
|
||||
|
||||
# Automation will set this to (file:///path/to/local, ...) via the mozconfig.
|
||||
# Local developer default is (jcenter, maven.google.com).
|
||||
option(env='GRADLE_MAVEN_REPOSITORIES',
|
||||
nargs='+',
|
||||
default=('https://jcenter.bintray.com/',
|
||||
'https://maven.google.com/',
|
||||
),
|
||||
help='Comma-separated URLs of Maven repositories containing Gradle dependencies.')
|
||||
|
||||
# Automation will set this to file:///path/to/local via the mozconfig.
|
||||
# Local developer default is jcenter.
|
||||
option(env='GRADLE_MAVEN_REPOSITORY', default='https://jcenter.bintray.com/',
|
||||
help='Path to Maven repository containing Gradle dependencies.')
|
||||
@depends('GRADLE_MAVEN_REPOSITORIES')
|
||||
@imports(_from='os.path', _import='isdir')
|
||||
def gradle_maven_repositories(values):
|
||||
if not values:
|
||||
die('GRADLE_MAVEN_REPOSITORIES must not be empty')
|
||||
if not all(values):
|
||||
die('GRADLE_MAVEN_REPOSITORIES entries must not be empty')
|
||||
return values
|
||||
|
||||
@depends('GRADLE_MAVEN_REPOSITORY')
|
||||
def gradle_maven_repository(value):
|
||||
if value:
|
||||
return value[0]
|
||||
|
||||
set_config('GRADLE_MAVEN_REPOSITORY', gradle_maven_repository)
|
||||
set_config('GRADLE_MAVEN_REPOSITORIES', gradle_maven_repositories)
|
||||
|
Loading…
Reference in New Issue
Block a user