Преглед на файлове

Speed `react-native run-android` up

j8
Lyubo Marinov преди 8 години
родител
ревизия
2fa7e777d6
променени са 3 файла, в които са добавени 19 реда и са изтрити 5 реда
  1. 1
    2
      android/app/build.gradle
  2. 17
    2
      android/build.gradle
  3. 1
    1
      android/gradle/wrapper/gradle-wrapper.properties

+ 1
- 2
android/app/build.gradle Целия файл

37
 dependencies {
37
 dependencies {
38
     compile fileTree(dir: 'libs', include: ['*.jar'])
38
     compile fileTree(dir: 'libs', include: ['*.jar'])
39
 
39
 
40
-    debugCompile project(path: ':sdk', configuration: 'debug')
41
-    releaseCompile project(path: ':sdk', configuration: 'release')
40
+    implementation project(':sdk')
42
 }
41
 }

+ 17
- 2
android/build.gradle Целия файл

4
 buildscript {
4
 buildscript {
5
     repositories {
5
     repositories {
6
         jcenter()
6
         jcenter()
7
+        maven { url 'https://maven.google.com' }
7
     }
8
     }
8
     dependencies {
9
     dependencies {
9
-        classpath 'com.android.tools.build:gradle:2.2.3'
10
+        classpath 'com.android.tools.build:gradle:3.+'
10
 
11
 
11
         // NOTE: Do not place your application dependencies here; they belong
12
         // NOTE: Do not place your application dependencies here; they belong
12
         // in the individual module build.gradle files.
13
         // in the individual module build.gradle files.
27
 
28
 
28
 ext {
29
 ext {
29
     compileSdkVersion = 23
30
     compileSdkVersion = 23
30
-    buildToolsVersion = "23.0.1"
31
+    buildToolsVersion = "25.0.3"
31
     minSdkVersion    = 16
32
     minSdkVersion    = 16
32
     targetSdkVersion = 22
33
     targetSdkVersion = 22
33
 }
34
 }
35
+
36
+// Force the version of the Android build tools we have chosen on all
37
+// subprojects. The forcing was introduced for react-native and the third-party
38
+// modules that we utilize such as react-native-background-timer.
39
+subprojects { subproject ->
40
+    afterEvaluate{
41
+        if (subproject.plugins.hasPlugin('android')
42
+                || subproject.plugins.hasPlugin('android-library')) {
43
+            android {
44
+                buildToolsVersion rootProject.ext.buildToolsVersion
45
+            }
46
+        }
47
+    }
48
+}

+ 1
- 1
android/gradle/wrapper/gradle-wrapper.properties Целия файл

2
 distributionPath=wrapper/dists
2
 distributionPath=wrapper/dists
3
 zipStoreBase=GRADLE_USER_HOME
3
 zipStoreBase=GRADLE_USER_HOME
4
 zipStorePath=wrapper/dists
4
 zipStorePath=wrapper/dists
5
-distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
5
+distributionUrl=https\://services.gradle.org/distributions/gradle-4.0-all.zip

Loading…
Отказ
Запис