Add product flavors. Switch to evernote's job scheduler

This commit is contained in:
len
2016-11-06 18:44:14 +01:00
parent 71fac76e3d
commit 2856d9d6a3
11 changed files with 152 additions and 168 deletions

View File

@@ -28,10 +28,6 @@ ext {
}
}
def includeUpdater() {
return hasProperty("include_updater")
}
android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
@@ -48,7 +44,6 @@ android {
buildConfigField "String", "COMMIT_COUNT", "\"${getCommitCount()}\""
buildConfigField "String", "COMMIT_SHA", "\"${getGitSha()}\""
buildConfigField "String", "BUILD_TIME", "\"${getBuildTime()}\""
buildConfigField "boolean", "INCLUDE_UPDATER", "${includeUpdater()}"
vectorDrawables.useSupportLibrary = true
@@ -71,6 +66,16 @@ android {
}
}
productFlavors {
standard {
buildConfigField "boolean", "INCLUDE_UPDATER", "true"
}
fdroid {
buildConfigField "boolean", "INCLUDE_UPDATER", "false"
}
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'LICENSE.txt'
@@ -108,6 +113,8 @@ dependencies {
compile 'com.android.support:multidex:1.0.1'
// Job scheduling
compile 'com.evernote:android-job:1.1.2'
compile 'com.google.android.gms:play-services-gcm:9.8.0'
// ReactiveX
@@ -117,6 +124,7 @@ dependencies {
// Network client
compile "com.squareup.okhttp3:okhttp:3.4.2"
compile 'com.squareup.okio:okio:1.11.0'
// REST
final retrofit_version = '2.1.0'
@@ -124,9 +132,6 @@ dependencies {
compile "com.squareup.retrofit2:converter-gson:$retrofit_version"
compile "com.squareup.retrofit2:adapter-rxjava:$retrofit_version"
// IO
compile 'com.squareup.okio:okio:1.11.0'
// JSON
compile 'com.google.code.gson:gson:2.8.0'
compile 'com.github.salomonbrys.kotson:kotson:2.4.0'
@@ -140,7 +145,7 @@ dependencies {
// Disk cache
compile 'com.jakewharton:disklrucache:2.0.2'
// Parse HTML
// HTML parser
compile 'org.jsoup:jsoup:1.10.1'
// Changelog