Skip to content

Commit b4c8985

Browse files
committed
Sync version used in build.gradle with react-native master
Add gradleBuildTools configuration to override gradle classpath
1 parent 131ddb6 commit b4c8985

1 file changed

Lines changed: 6 additions & 14 deletions

File tree

android/build.gradle

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,22 @@ def safeExtGet(prop, fallback) {
44

55
buildscript {
66
repositories {
7-
jcenter()
87
google()
9-
maven {
10-
url 'https://maven.google.com/'
11-
name 'Google'
12-
}
8+
jcenter()
139
}
1410

1511
dependencies {
1612
//noinspection GradleDependency
17-
classpath 'com.android.tools.build:gradle:3.2.1'
13+
classpath rootProject.ext.has('gradleBuildTools') ? rootProject.ext.get('gradleBuildTools') : 'com.android.tools.build:gradle:3.3.0'
1814
}
1915
}
2016

2117
apply plugin: 'com.android.library'
2218

2319
android {
24-
compileSdkVersion safeExtGet('compileSdkVersion', 27)
20+
compileSdkVersion safeExtGet('compileSdkVersion', 28)
2521
//noinspection GradleDependency
26-
buildToolsVersion safeExtGet('buildToolsVersion', '27.0.3')
22+
buildToolsVersion safeExtGet('buildToolsVersion', '28.0.3')
2723

2824
defaultConfig {
2925
minSdkVersion safeExtGet('minSdkVersion', 16)
@@ -37,15 +33,11 @@ android {
3733

3834
repositories {
3935
mavenLocal()
40-
jcenter()
4136
google()
37+
jcenter()
4238
maven {
4339
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
44-
url "$projectDir/../../../node_modules/react-native/android"
45-
}
46-
maven {
47-
url 'https://maven.google.com/'
48-
name 'Google'
40+
url "$rootDir/../node_modules/react-native/android"
4941
}
5042
}
5143

0 commit comments

Comments
 (0)