1 | apply plugin: 'com.android.library'
|
2 | apply plugin: 'kotlin-android'
|
3 | apply plugin: 'maven'
|
4 |
|
5 | buildscript {
|
6 |
|
7 | ext.safeExtGet = { prop, fallback ->
|
8 | rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
|
9 | }
|
10 |
|
11 | repositories {
|
12 | mavenCentral()
|
13 | }
|
14 |
|
15 | dependencies {
|
16 | classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${safeExtGet("kotlinVersion", "1.3.50")}")
|
17 | }
|
18 | }
|
19 |
|
20 | group = 'host.exp.exponent'
|
21 | version = '1.1.1'
|
22 |
|
23 |
|
24 | configurations {
|
25 | deployerJars
|
26 | }
|
27 |
|
28 |
|
29 | task androidSourcesJar(type: Jar) {
|
30 | classifier = 'sources'
|
31 | from android.sourceSets.main.java.srcDirs
|
32 | }
|
33 |
|
34 |
|
35 | artifacts {
|
36 | archives androidSourcesJar
|
37 | }
|
38 |
|
39 | uploadArchives {
|
40 | repositories {
|
41 | mavenDeployer {
|
42 | configuration = configurations.deployerJars
|
43 | repository(url: mavenLocal().url)
|
44 | }
|
45 | }
|
46 | }
|
47 |
|
48 | android {
|
49 | compileSdkVersion safeExtGet("compileSdkVersion", 29)
|
50 |
|
51 | defaultConfig {
|
52 | minSdkVersion safeExtGet("minSdkVersion", 21)
|
53 | targetSdkVersion safeExtGet("targetSdkVersion", 28)
|
54 | versionCode 5
|
55 | versionName "1.1.1"
|
56 | }
|
57 | lintOptions {
|
58 | abortOnError false
|
59 | }
|
60 | compileOptions {
|
61 | sourceCompatibility = '1.8'
|
62 | targetCompatibility = '1.8'
|
63 | }
|
64 | }
|
65 |
|
66 | repositories {
|
67 | mavenCentral()
|
68 | }
|
69 |
|
70 | if (new File(rootProject.projectDir.parentFile, 'package.json').exists()) {
|
71 | apply from: project(":unimodules-core").file("../unimodules-core.gradle")
|
72 | } else {
|
73 | throw new GradleException(
|
74 | '\'unimodules-core.gradle\' was not found in the usual Flutter or React Native dependency locations. ' +
|
75 | 'This package can only be used in such projects. Are you sure you\'ve installed the dependencies properly?')
|
76 | }
|
77 |
|
78 | dependencies {
|
79 | unimodule 'unimodules-core'
|
80 | unimodule 'unimodules-image-loader-interface'
|
81 |
|
82 | api "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${safeExtGet('kotlinVersion', '1.3.50')}"
|
83 | api 'com.github.bumptech.glide:glide:4.9.0'
|
84 | api 'com.facebook.fresco:fresco:2.0.0'
|
85 | }
|