-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathbuild.gradle
More file actions
139 lines (117 loc) · 4.49 KB
/
build.gradle
File metadata and controls
139 lines (117 loc) · 4.49 KB
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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext {
BUILD_TOOLS_VERSION = '26.0.0-rc1'
COMPILE_SDK_VERSION = 25
MIN_SDK_VERSION = 14
TARGET_SDK_VERSON = 25
KOTLIN_VERSION = '1.1.2-3'
ANDROID_GRADLE_VERSION = '2.3.0'
ANDROID_SUPPORT_VERSION = '25.3.1'
DAGGER_VERSION = '2.11-rc2'
GSON_VERSION = '2.8.0'
SLF4J_ANDROID_VERSION = '1.7.19'
EVENT_BUS_VERSION = '3.0.0'
DIRCHOOSER_VERSION = '3.2'
}
repositories {
maven { url "http://maven.aliyun.com/nexus/content/groups/public"}
mavenCentral()
jcenter()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$KOTLIN_VERSION"
classpath "com.android.tools.build:gradle:$ANDROID_GRADLE_VERSION"
}
}
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-kapt'
android {
compileSdkVersion COMPILE_SDK_VERSION
buildToolsVersion BUILD_TOOLS_VERSION
dataBinding {
enabled = true
}
defaultConfig {
applicationId "org.mdvsc.vcserver"
versionCode 1
versionName '1.0.0'
minSdkVersion MIN_SDK_VERSION
targetSdkVersion TARGET_SDK_VERSON
}
signingConfigs {
release {
Properties properties = new Properties()
try {
properties.load(project.rootProject.file('local.properties').newDataInputStream())
} catch (Exception ignored) {
println('cannot find local.properties.')
}
String keystoreFileProperty = properties.getProperty('KEYSTORE')
String keystorePasswordProperty = properties.getProperty('KEYSTORE_PASSWORD')
String keyAliasProperty = properties.getProperty('KEY_ALIAS')
String keyPasswordProperty = properties.getProperty('KEY_PASSWORD')
keystoreFileProperty = keystoreFileProperty == null ? System.getenv('KEYSTORE') : keystoreFileProperty
keystorePasswordProperty = keystorePasswordProperty == null ? System.getenv('KEYSTORE_PASSWORD') : keystorePasswordProperty
keyAliasProperty = keyAliasProperty == null ? System.getenv('KEY_ALIAS') : keyAliasProperty
keyPasswordProperty = keyPasswordProperty == null ? System.getenv('KEY_PASSWORD') : keyPasswordProperty
if (keystoreFileProperty != null) {
storeFile file(keystoreFileProperty)
storePassword keystorePasswordProperty
keyAlias keyAliasProperty
keyPassword keyPasswordProperty
}
}
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
signingConfig signingConfigs.release
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_7
targetCompatibility JavaVersion.VERSION_1_7
}
packagingOptions {
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/LICENSE'
exclude 'META-INF/NOTICE'
}
lintOptions {
abortOnError false
}
sourceSets {
main {
java.srcDirs += 'src/main/kotlin'
jniLibs.srcDirs = ['libs']
}
}
}
repositories {
maven { url "http://maven.aliyun.com/nexus/content/groups/public"}
mavenCentral()
jcenter()
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'org.apache.sshd:sshd-core:0.14.0'
compile 'org.apache.mina:mina-core:2.0.13'
compile 'org.eclipse.jgit:org.eclipse.jgit:3.7.1.201504261725-r'
compile "net.rdrei.android.dirchooser:library:$DIRCHOOSER_VERSION@aar"
compile "org.greenrobot:eventbus:$EVENT_BUS_VERSION"
compile "org.slf4j:slf4j-android:$SLF4J_ANDROID_VERSION"
compile "com.google.code.gson:gson:$GSON_VERSION"
compile "org.jetbrains.kotlin:kotlin-stdlib:$KOTLIN_VERSION"
compile "com.android.support:design:$ANDROID_SUPPORT_VERSION"
compile "com.android.support:preference-v14:$ANDROID_SUPPORT_VERSION"
compile "com.android.support:recyclerview-v7:$ANDROID_SUPPORT_VERSION"
compile "com.google.dagger:dagger:$DAGGER_VERSION"
kapt "com.google.dagger:dagger-compiler:$DAGGER_VERSION"
kapt "com.android.databinding:compiler:$ANDROID_GRADLE_VERSION"
}