File tree Expand file tree Collapse file tree 1 file changed +17
-11
lines changed Expand file tree Collapse file tree 1 file changed +17
-11
lines changed Original file line number Diff line number Diff line change @@ -3,25 +3,30 @@ def safeExtGet(prop, fallback) {
3
3
}
4
4
5
5
buildscript {
6
- repositories {
7
- google()
8
- jcenter()
9
- }
10
-
11
- dependencies {
12
- classpath ' com.android.tools.build:gradle:3.5.2'
6
+ // The Android Gradle plugin is only required when opening the android folder stand-alone.
7
+ // This avoids unnecessary downloads and potential conflicts when the library is included as a
8
+ // module dependency in an application project.
9
+ if (project == rootProject) {
10
+ repositories {
11
+ google()
12
+ jcenter()
13
+ }
14
+
15
+ dependencies {
16
+ classpath(" com.android.tools.build:gradle:3.5.3" )
17
+ }
13
18
}
14
19
}
15
20
16
21
apply plugin : ' com.android.library'
17
22
18
23
android {
19
- compileSdkVersion safeExtGet(' compileSdkVersion' , 25 )
20
- buildToolsVersion safeExtGet(' buildToolsVersion' , ' 25 .0.3' )
24
+ compileSdkVersion safeExtGet(' compileSdkVersion' , 28 )
25
+ buildToolsVersion safeExtGet(' buildToolsVersion' , ' 28 .0.3' )
21
26
22
27
defaultConfig {
23
28
minSdkVersion safeExtGet(' minSdkVersion' , 16 )
24
- targetSdkVersion safeExtGet(' targetSdkVersion' , 22 )
29
+ targetSdkVersion safeExtGet(' targetSdkVersion' , 28 )
25
30
versionCode 1
26
31
versionName " 1.0"
27
32
@@ -34,7 +39,8 @@ android {
34
39
}
35
40
36
41
repositories {
37
- mavenCentral()
42
+ google()
43
+ jcenter()
38
44
}
39
45
40
46
dependencies {
You can’t perform that action at this time.
0 commit comments