UNPKG

1.95 kBPlain TextView Raw
1buildscript {
2 // Simple helper that allows the root project to override versions declared by this library.
3 ext.safeExtGet = { prop, fallback ->
4 rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
5 }
6
7 repositories {
8 mavenCentral()
9 }
10
11 dependencies {
12 classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${safeExtGet("kotlinVersion", "1.3.50")}")
13 }
14}
15
16apply plugin: 'com.android.library'
17apply plugin: 'maven'
18apply plugin: 'kotlin-android'
19
20group = 'org.unimodules'
21version = '6.1.0'
22
23
24// Simple helper that allows the root project to override versions declared by this library.
25def safeExtGet(prop, fallback) {
26 rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
27}
28
29//Upload android library to maven with javadoc and android sources
30configurations {
31 deployerJars
32}
33
34//Creating sources with comments
35task androidSourcesJar(type: Jar) {
36 classifier = 'sources'
37 from android.sourceSets.main.java.srcDirs
38}
39
40//Put the androidSources and javadoc to the artifacts
41artifacts {
42 archives androidSourcesJar
43}
44
45uploadArchives {
46 repositories {
47 mavenDeployer {
48 configuration = configurations.deployerJars
49 repository(url: mavenLocal().url)
50 }
51 }
52}
53
54android {
55 compileSdkVersion safeExtGet("compileSdkVersion", 29)
56
57 defaultConfig {
58 minSdkVersion safeExtGet("minSdkVersion", 21)
59 targetSdkVersion safeExtGet("targetSdkVersion", 29)
60 versionCode 23
61 versionName "6.1.0"
62 }
63 lintOptions {
64 abortOnError false
65 }
66}
67
68apply from: project(":unimodules-core").file("../unimodules-core.gradle")
69
70dependencies {
71 unimodule 'unimodules-core'
72 unimodule 'unimodules-font-interface'
73 unimodule 'unimodules-permissions-interface'
74 unimodule 'unimodules-image-loader-interface'
75 unimodule 'unimodules-app-loader'
76
77 implementation 'com.facebook.react:react-native:+'
78
79 implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${safeExtGet('kotlinVersion', '1.3.50')}"
80
81}