/
build.gradle
231 lines (191 loc) · 8.91 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
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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
apply plugin: 'com.android.application'
apply plugin: 'com.bugsnag.android.gradle'
def keystorePropertiesFile = rootProject.file("keystore.properties")
def keystoreProperties = new Properties()
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
android {
compileSdkVersion 29
defaultConfig {
applicationId "eu.faircode.email"
minSdkVersion 21
targetSdkVersion 29
versionCode 568
versionName "1.568"
archivesBaseName = "FairEmail-v$versionName"
javaCompileOptions {
annotationProcessorOptions {
arguments = ["room.schemaLocation": "$projectDir/schemas".toString()]
}
}
// https://developer.android.com/guide/topics/graphics/vector-drawable-resources
vectorDrawables.useSupportLibrary = true
ndk {
// Bugsnag
abiFilters "armeabi-v7a", "x86", "arm64-v8a", "x86_64"
}
}
signingConfigs {
release {
storeFile file(keystoreProperties['storeFile'])
storePassword keystoreProperties['storePassword']
keyAlias keystoreProperties['keyAlias']
keyPassword keystoreProperties['keyPassword']
}
}
buildTypes {
release {
debuggable = false
minifyEnabled = true
useProguard = true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
}
debug {
debuggable = true
minifyEnabled = false
useProguard = false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
flavorDimensions "all"
productFlavors {
full {
dimension "all"
buildConfigField "boolean", "BETA_RELEASE", "true"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "false"
buildConfigField "String", "INVITE_URI", "\"https://email.faircode.eu/\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/donate/\""
buildConfigField "String", "CHANGELOG", "\"https://github.com/M66B/open-source-email/releases/\""
buildConfigField "String", "GITHUB_LATEST_API", "\"https://api.github.com/repos/M66B/open-source-email/releases/latest\""
}
play_beta {
dimension "all"
buildConfigField "boolean", "BETA_RELEASE", "true"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "true"
buildConfigField "String", "INVITE_URI", "\"https://play.google.com/store/apps/details?id=eu.faircode.email\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/#pro\""
buildConfigField "String", "CHANGELOG", "\"\""
buildConfigField "String", "GITHUB_LATEST_API", "\"\""
}
play_release {
dimension "all"
buildConfigField "boolean", "BETA_RELEASE", "false"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "true"
buildConfigField "String", "INVITE_URI", "\"https://play.google.com/store/apps/details?id=eu.faircode.email\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/#pro\""
buildConfigField "String", "CHANGELOG", "\"\""
buildConfigField "String", "GITHUB_LATEST_API", "\"\""
}
}
lintOptions {
disable 'MissingTranslation'
abortOnError false
}
packagingOptions {
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/README.md'
exclude 'META-INF/CHANGES'
}
bugsnag {
// https://docs.bugsnag.com/build-integrations/gradle/
apiKey "9d2d57476a0614974449a3ec33f2604a"
builderName "M66B"
autoUpload false
autoReportBuilds false
sourceControl {
repository "https://github.com/M66B/open-source-email"
}
}
}
repositories {
google()
jcenter()
maven { url "https://repo1.maven.org/maven2/" }
maven { url "https://jitpack.io" }
}
configurations.all {
exclude group: "androidx.lifecycle", module: "lifecycle-livedata"
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
def appcompat_version = "1.1.0-beta01"
def recyclerview_version = "1.1.0-alpha06"
def coordinatorlayout_version = "1.1.0-beta01"
def constraintlayout_version = "2.0.0-beta1"
def material_version = "1.1.0-alpha07"
def browser_version = "1.0.0"
def lifecycle_version = "2.1.0-beta01"
def room_version = "2.1.0"
def paging_version = "2.1.0"
def preference_version = "1.1.0-beta01"
def work_version = "2.1.0-rc01"
def exif_version = "1.1.0-alpha01"
def billingclient_version = "2.0.1"
def javamail_version = "1.6.3"
def jsoup_version = "1.12.1"
def dnsjava_version = "2.1.9"
def openpgp_version = "12.0"
def requery_version = "3.28.0"
def badge_version = "1.1.22"
def bugsnag_version = "4.15.0"
def biweekly_version = "0.6.3"
// https://developer.android.com/jetpack/androidx/releases/
// https://mvnrepository.com/artifact/androidx.appcompat/appcompat
implementation "androidx.appcompat:appcompat:$appcompat_version"
// https://mvnrepository.com/artifact/androidx.recyclerview/recyclerview
// https://mvnrepository.com/artifact/androidx.recyclerview/recyclerview-selection
implementation "androidx.recyclerview:recyclerview:$recyclerview_version"
//implementation "androidx.recyclerview:recyclerview-selection:1.1.0-alpha06"
// https://mvnrepository.com/artifact/androidx.coordinatorlayout/coordinatorlayout
implementation "androidx.coordinatorlayout:coordinatorlayout:$coordinatorlayout_version"
// https://mvnrepository.com/artifact/androidx.constraintlayout/constraintlayout
implementation "androidx.constraintlayout:constraintlayout:$constraintlayout_version"
// https://mvnrepository.com/artifact/com.google.android.material/material
// https://github.com/material-components/material-components-android/releases
implementation "com.google.android.material:material:$material_version"
// https://mvnrepository.com/artifact/androidx.browser/browser
implementation "androidx.browser:browser:$browser_version"
// https://mvnrepository.com/artifact/androidx.lifecycle/lifecycle-runtime
implementation "androidx.lifecycle:lifecycle-extensions:$lifecycle_version"
annotationProcessor "androidx.lifecycle:lifecycle-compiler:$lifecycle_version"
// https://mvnrepository.com/artifact/androidx.room/room-runtime
implementation "androidx.room:room-runtime:$room_version"
annotationProcessor "androidx.room:room-compiler:$room_version"
// https://mvnrepository.com/artifact/androidx.paging/paging-runtime
implementation "androidx.paging:paging-runtime:$paging_version"
// https://mvnrepository.com/artifact/androidx.preference/preference
implementation "androidx.preference:preference:$preference_version"
// https://mvnrepository.com/artifact/android.arch.work/work-runtime
implementation "androidx.work:work-runtime:$work_version"
// https://mvnrepository.com/artifact/androidx.exifinterface/exifinterface
implementation "androidx.exifinterface:exifinterface:$exif_version"
// https://developer.android.com/google/play/billing/billing_library_releases_notes
implementation "com.android.billingclient:billing:$billingclient_version"
// https://javaee.github.io/javamail/
// https://projects.eclipse.org/projects/ee4j.javamail
// https://mvnrepository.com/artifact/com.sun.mail
implementation "com.sun.mail:android-mail:$javamail_version"
implementation "com.sun.mail:android-activation:$javamail_version"
// https://jsoup.org/
implementation "org.jsoup:jsoup:$jsoup_version"
// http://www.dnsjava.org/
// https://mvnrepository.com/artifact/dnsjava/dnsjava
implementation "dnsjava:dnsjava:$dnsjava_version"
// https://github.com/open-keychain/openpgp-api
implementation "org.sufficientlysecure:openpgp-api:$openpgp_version"
// https://www.sqlite.org/changes.html
// https://github.com/requery/sqlite-android/
// https://mvnrepository.com/artifact/io.requery/sqlite-android?repo=jcenter
implementation "io.requery:sqlite-android:$requery_version"
// https://github.com/leolin310148/ShortcutBadger
// https://mvnrepository.com/artifact/me.leolin/ShortcutBadger
implementation "me.leolin:ShortcutBadger:$badge_version"
// https://github.com/bugsnag/bugsnag-android
implementation "com.bugsnag:bugsnag-android:$bugsnag_version"
// https://github.com/mangstadt/biweekly
implementation("net.sf.biweekly:biweekly:$biweekly_version") {
exclude group: 'com.fasterxml.jackson.core', module: 'jackson-core'
}
// git clone https://android.googlesource.com/platform/frameworks/opt/colorpicker
implementation project(path: ':colorpicker')
}