thorium-fork/app/build.gradle

176 lines
6.4 KiB
Groovy
Raw Normal View History

plugins {
id 'com.android.application'
id 'kotlin-android'
id 'kotlin-parcelize'
id 'kotlin-kapt'
}
2018-03-02 16:10:13 -08:00
ext.readProperty = { paramName -> readPropertyWithDefault(paramName, null) }
ext.readPropertyWithDefault = { paramName, defaultValue ->
if (project.hasProperty(paramName)) {
return project.getProperties().get(paramName)
} else {
Properties properties = new Properties()
if (project.rootProject.file('local.properties').exists()) {
properties.load(project.rootProject.file('local.properties').newDataInputStream())
}
if (properties.getProperty(paramName) != null) {
return properties.getProperty(paramName)
} else {
return defaultValue
}
}
}
2020-08-29 13:33:23 -07:00
// Try reading secrets from file
def secretsPropertiesFile = rootProject.file("secrets.properties")
def secretProperties = new Properties()
if (secretsPropertiesFile.exists()) {
secretProperties.load(new FileInputStream(secretsPropertiesFile))
}
// Otherwise read from environment variables, this happens in CI
else {
secretProperties.setProperty("signing_keystore_password", "${System.getenv('signing_keystore_password')}")
secretProperties.setProperty("signing_key_password", "${System.getenv('signing_key_password')}")
secretProperties.setProperty("signing_key_alias", "${System.getenv('signing_key_alias')}")
}
2021-10-04 00:42:35 -07:00
apply plugin: 'kotlin-kapt'
2018-03-02 16:10:13 -08:00
android {
2020-06-21 08:01:15 -07:00
compileSdkVersion 29
2021-10-04 00:42:35 -07:00
buildToolsVersion "30.0.2"
2021-01-13 12:31:05 -08:00
2018-03-02 16:10:13 -08:00
defaultConfig {
applicationId "net.schueller.peertube"
minSdkVersion 21
2020-06-21 08:01:15 -07:00
targetSdkVersion 29
chore(release): 1.5.0 [only cd] # 1.5.0 (2021-10-05) ### Bug Fixes * Added missing description files required for fastlane 38eb072 * android update 9fc9804 * android update 9800140 * android update 5f1ea69 * android update 2ccb9fd * android update be6f946 * android update 3a7ca15 * android update f71aeb2 * android update 48007d3 * android update 1996d30 * android update 18c390d * android update 011a605 * android update 4d198df * android update 20d41d5 * android update cb9801b * android update 3e168e6 * android update eb28e81 * jdk update 8889ab1 * jdk update ddb0f73 * **lang:** Weblate translation (Albanian) 0c2de46 * **lang:** Weblate translation (Albanian) 20ee0aa * **lang:** Weblate translation (Bengali (Bangladesh)) e2ced85 * **lang:** Weblate translation (Bengali (Bangladesh)) 0da8653 * **lang:** Weblate translation (Bengali) cc34d94 * **lang:** Weblate translation (Finnish) cd64314 * **lang:** Weblate translation (French) 5b539f9 * **lang:** Weblate translation (French) 2a02143 * **lang:** Weblate translation (Indonesian) eea466c * **lang:** Weblate translation (Italian) 8b2f5e5 * **lang:** Weblate translation (Persian) 7bff5f1 * **lang:** Weblate translation (Portuguese) d0dd108 * **lang:** Weblate translation (Russian (ru_CARES)) be41b42 * **lang:** Weblate translation (Russian) cc6a1b8 * **lang:** Weblate translation (Sardinian) 952eb36 * **lang:** Weblate translation (Sinhala) 1b7007a * **lang:** Weblate translation (Spanish) f94374c * **lang:** Weblate translation (Albanian) 970c27a * **lang:** Weblate translation (Arabic) 4f1d27f * **lang:** Weblate translation (Arabic) 5d811cc * **lang:** Weblate translation (Arabic) 53047c9 * **lang:** Weblate translation (Bengali (Bangladesh)) 2e21b02 * **lang:** Weblate translation (Bengali (Bangladesh)) a6fbe44 * **lang:** Weblate translation (Bengali) 937175d * **lang:** Weblate translation (Bengali) 9cdce0c * **lang:** Weblate translation (Bengali) 9686f61 * **lang:** Weblate translation (Czech) 2824300 * **lang:** Weblate translation (Esperanto) 841d711 * **lang:** Weblate translation (Esperanto) 8d69ea5 * **lang:** Weblate translation (Finnish) bfb80c4 * **lang:** Weblate translation (French) 8a05579 * **lang:** Weblate translation (French) 6ff05b5 * **lang:** Weblate translation (German) 8fef278 * **lang:** Weblate translation (German) 8028936 * **lang:** Weblate translation (Greek) 553869d * **lang:** Weblate translation (Greek) 05f0369 * **lang:** Weblate translation (Indonesian) ebae5e2 * **lang:** Weblate translation (Indonesian) ae5462a * **lang:** Weblate translation (Italian) 4adbe6f * **lang:** Weblate translation (Japanese) d873254 * **lang:** Weblate translation (Japanese) e7cf39d * **lang:** Weblate translation (Norwegian Bokmål) fc02ce1 * **lang:** Weblate translation (Persian) 71ab54e * **lang:** Weblate translation (Portuguese (Brazil)) 3887cda * **lang:** Weblate translation (Portuguese) ce48913 * **lang:** Weblate translation (Portuguese) 7d790d3 * **lang:** Weblate translation (Russian) a464d50 * **lang:** Weblate translation (Russian) 632af1a * **lang:** Weblate translation (Russian) 5f115d3 * **lang:** Weblate translation (Sinhala) abca190 * **lang:** Weblate translation (Spanish) 63324bc * **lang:** Weblate translation (Swedish) 5608c0d * **lang:** Weblate translation (Swedish) 376e05c * **lang:** Weblate translation (Ukrainian) 3dc4867 * node version 36b840f * node version 3ee6071 * Updated gradle in docker 79c9e97 ### Features * Android lib updates, gradle update 5f2847c * **lang:** Added translation using Weblate (Albanian) 773f108 * **lang:** Added translation using Weblate (Esperanto) a2880f7 * **lang:** Added translation using Weblate (Sardinian) ccc7723 * **lang:** Added translation using Weblate (Sinhala) 4d48100
2021-10-05 13:36:42 -07:00
versionCode 1061
versionName "1.5.0"
2020-07-08 03:31:30 -07:00
buildConfigField "long", "BUILD_TIME", readPropertyWithDefault('buildTimestamp', System.currentTimeMillis()) + 'L'
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
2021-01-13 12:31:05 -08:00
2020-06-21 08:01:15 -07:00
javaCompileOptions {
annotationProcessorOptions {
arguments = [
"room.schemaLocation" : "$projectDir/schemas".toString(),
"room.incremental" : "true",
"room.expandProjection": "true"]
}
}
2018-03-02 16:10:13 -08:00
}
2020-08-29 13:33:23 -07:00
signingConfigs {
release {
// You need to specify either an absolute path or include the
// keystore file in the same directory as the build.gradle file.
storeFile file("../android-signing-keystore.jks")
storePassword "${secretProperties['signing_keystore_password']}"
keyAlias "${secretProperties['signing_key_alias']}"
keyPassword "${secretProperties['signing_key_password']}"
}
}
2018-03-02 16:10:13 -08:00
buildTypes {
release {
minifyEnabled false
2020-08-29 13:33:23 -07:00
testCoverageEnabled false
2018-03-02 16:10:13 -08:00
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
2020-08-29 13:33:23 -07:00
signingConfig signingConfigs.release
2018-03-02 16:10:13 -08:00
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
2018-11-10 08:48:09 -08:00
applicationVariants.all { variant ->
variant.resValue "string", "versionName", variant.versionName
}
buildFeatures{
viewBinding = true
}
2018-03-02 16:10:13 -08:00
}
2021-10-04 00:42:35 -07:00
def room_version = "2.3.0"
def lifecycleVersion = '2.3.1'
2021-01-13 12:31:05 -08:00
def exoplayer = '2.12.3'
2021-10-04 00:42:35 -07:00
def fragment_version = "1.3.6"
2021-01-13 12:31:05 -08:00
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
2020-06-21 08:01:15 -07:00
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
2021-01-13 12:31:05 -08:00
// Layouts and design
2021-10-04 00:42:35 -07:00
implementation 'androidx.constraintlayout:constraintlayout:2.1.1'
implementation 'androidx.appcompat:appcompat:1.3.1'
implementation 'com.google.android.material:material:1.4.0'
2021-01-13 12:31:05 -08:00
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
implementation "androidx.fragment:fragment-ktx:$fragment_version"
2021-01-13 12:31:05 -08:00
2021-01-23 15:31:51 -08:00
implementation 'de.hdodenhof:circleimageview:3.1.0'
2021-01-13 12:31:05 -08:00
// font awesome
2021-01-23 15:31:51 -08:00
implementation 'com.mikepenz:iconics-core:5.2.4'
implementation 'com.mikepenz:fontawesome-typeface:5.9.0.2-kotlin@aar'
2021-01-13 12:31:05 -08:00
// http client / REST
2021-10-04 00:42:35 -07:00
implementation 'com.squareup.okhttp3:okhttp:4.9.1'
2021-01-13 12:31:05 -08:00
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
// image downloading and caching library
implementation 'com.squareup.picasso:picasso:2.71828'
// json decoder/encoder
implementation 'com.google.code.gson:gson:2.8.6'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
// Torrents and WebRTC
implementation 'com.github.TorrentStream:TorrentStream-Android:2.7.0'
// implementation "com.github.TorrentStream:TorrentStreamServer-Android:1.0.1"
// implementation 'org.webrtc:google-webrtc:1.0.+'
// video player repo:jcenter()
implementation "com.google.android.exoplayer:exoplayer-core:$exoplayer"
implementation "com.google.android.exoplayer:exoplayer-dash:$exoplayer"
implementation "com.google.android.exoplayer:exoplayer-ui:$exoplayer"
implementation "com.google.android.exoplayer:exoplayer-hls:$exoplayer"
implementation "com.google.android.exoplayer:exoplayer-smoothstreaming:$exoplayer"
implementation "com.google.android.exoplayer:extension-mediasession:$exoplayer"
implementation "com.google.android.exoplayer:extension-okhttp:$exoplayer"
// date formatter, do not update past 4.0.4 https://github.com/sschueller/peertube-android/issues/262
implementation 'org.ocpsoft.prettytime:prettytime:4.0.4.Final'
2021-01-13 12:31:05 -08:00
// Version comparison
2021-01-23 15:31:51 -08:00
implementation 'org.apache.maven:maven-artifact:3.6.3'
2020-06-21 08:01:15 -07:00
// database lib
implementation "androidx.room:room-runtime:$room_version"
implementation "androidx.room:room-ktx:$room_version"
kapt "androidx.room:room-compiler:$room_version"
2020-06-21 08:01:15 -07:00
// Lifecycle components
2021-10-04 00:42:35 -07:00
kapt "androidx.lifecycle:lifecycle-common-java8:$lifecycleVersion"
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycleVersion"
implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycleVersion"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycleVersion"
implementation 'androidx.preference:preference-ktx:1.1.1'
2021-01-13 12:31:05 -08:00
// testing
2021-01-23 15:31:51 -08:00
testImplementation 'junit:junit:4.13.1'
2021-10-04 00:42:35 -07:00
androidTestImplementation 'androidx.test:runner:1.4.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
androidTestImplementation "androidx.room:room-testing:$room_version"
2018-12-17 09:11:41 -08:00
}
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
kotlinOptions {
jvmTarget = "1.8"
}
2021-01-31 14:35:16 -08:00
}