-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
96 lines (87 loc) · 3.22 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
dependencies {
classpath Tools.gradle
classpath Tools.kotlin_gradle_plugin
classpath Tools.artifactory
// classpath Tools.navigation_safe_args_gradle_plugin
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
repositories {
google()
}
}
plugins {
id "com.github.ben-manes.versions" version "0.42.0"
}
allprojects {
apply plugin: 'maven-publish'
apply plugin: "com.jfrog.artifactory"
repositories {
maven {
def machineIP = System.getenv('ARTIFACTORY_MACHINE_IP')
def contextUrl = "http://${machineIP}:8081/artifactory"
def repoKey = "libs-release-local"
url "${contextUrl}/${repoKey}"
credentials {
username = System.getenv('ARTIFACTORY_USERNAME')
password = System.getenv('ARTIFACTORY_PASSWORD')
}
allowInsecureProtocol true
}
google()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
subprojects {
afterEvaluate { project ->
if (project.hasProperty('android')) {
android {
compileSdkVersion Config.compileSdk
buildToolsVersion Config.buildTools
defaultConfig {
minSdkVersion Config.minSdk
targetSdkVersion Config.targetSdk
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
buildTypes {
release {
// Enables code shrinking, obfuscation, and optimization for only
// your project's release build type.
// minifyEnabled true
// Enables resource shrinking, which is performed by the
// Android Gradle plugin.
// shrinkResources true
// Includes the default ProGuard rules files that are packaged with
// the Android Gradle plugin. To learn more, go to the section about
// R8 configuration files.
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
configurations.all {
// Check for updates every build
resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
}
testOptions {
unitTests.includeAndroidResources = true
}
packagingOptions {
exclude 'META-INF/atomicfu.kotlin_module'
}
buildFeatures {
dataBinding true
}
lintOptions {
warning 'InvalidPackage'
abortOnError false
}
}
}
}
}