Skip to content

Commit

Permalink
build: updates (#63)
Browse files Browse the repository at this point in the history
* Update Java base to 17
* update Kotlin to 1.8.22
* update Bouncycastle
* update all dependencies
* follow the manifest on jni libs packaging
* enhance app optimization by specifying resource configurations, excluding dependencies info and unnessesary files
* Remove obsolete SDK check as we are already using minSdk 26

Signed-off-by: Patryk Miś <foss@patrykmis.com>
  • Loading branch information
PatrykMis authored and oSumAtrIX committed Aug 26, 2023
1 parent b7a08ac commit 710fca4
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 15 deletions.
36 changes: 26 additions & 10 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ plugins {
alias(libs.plugins.kotlin.android)
alias(libs.plugins.devtools)
id("kotlin-parcelize")
kotlin("plugin.serialization") version "1.8.21"
kotlin("plugin.serialization") version "1.8.22"
}

android {
Expand All @@ -17,6 +17,9 @@ android {
targetSdk = 33
versionCode = 1
versionName = "0.0.1"
resourceConfigurations.addAll(listOf(
"en",
))

vectorDrawables.useSupportLibrary = true
}
Expand All @@ -30,14 +33,27 @@ android {
}

compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

dependenciesInfo {
includeInApk = false
includeInBundle = false
}
packaging {
resources {
excludes += "/prebuilt/**"
excludes += "META-INF/DEPENDENCIES"
resources.excludes.addAll(listOf(
"/prebuilt/**",
"META-INF/DEPENDENCIES",
"META-INF/**.version",
"DebugProbesKt.bin",
"kotlin-tooling-metadata.json",
"kotlin/**.kotlin_builtins",
"org/bouncycastle/pqc/**.properties",
"org/bouncycastle/x509/**.properties",
}
jniLibs {
useLegacyPackaging = true
}
}

Expand All @@ -46,16 +62,16 @@ android {
}

kotlinOptions {
jvmTarget = "11"
jvmTarget = "17"
}

buildFeatures.compose = true

composeOptions.kotlinCompilerExtensionVersion = "1.4.7"
composeOptions.kotlinCompilerExtensionVersion = "1.4.8"
}

kotlin {
jvmToolchain(11)
jvmToolchain(17)
}

dependencies {
Expand Down Expand Up @@ -105,7 +121,7 @@ dependencies {

// Signing
implementation(libs.apksign)
implementation(libs.bcpkix.jdk15on)
implementation(libs.bcpkix.jdk18on)

// Koin
implementation(libs.koin.android)
Expand Down
10 changes: 5 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@ collection = "0.3.5"
room-version = "2.5.2"
patcher = "11.0.4"
apksign = "8.0.2"
bcpkix-jdk15on = "1.70"
bcpkix-jdk18on = "1.75"
koin-version = "3.4.2"
koin-version-compose = "3.4.5"
reimagined-navigation = "1.4.0"
ktor = "2.3.2"
markdown = "0.4.1"
androidGradlePlugin = "8.0.2"
kotlinGradlePlugin = "1.8.21"
devToolsGradlePlugin = "1.8.21-1.0.11"
aboutLibrariesGradlePlugin = "10.8.0"
kotlinGradlePlugin = "1.8.22"
devToolsGradlePlugin = "1.8.22-1.0.11"
aboutLibrariesGradlePlugin = "10.8.2"
coil = "2.4.0"
app-icon-loader-coil = "1.5.0"
skrapeit = "1.2.1"
Expand Down Expand Up @@ -71,7 +71,7 @@ patcher = { group = "app.revanced", name = "revanced-patcher", version.ref = "pa

# Signing
apksign = { group = "com.android.tools.build", name = "apksig", version.ref = "apksign" }
bcpkix-jdk15on = { group = "org.bouncycastle", name = "bcpkix-jdk15on", version.ref = "bcpkix-jdk15on" }
bcpkix-jdk18on = { group = "org.bouncycastle", name = "bcpkix-jdk18on", version.ref = "bcpkix-jdk18on" }

# Koin
koin-android = { group = "io.insert-koin", name = "koin-android", version.ref = "koin-version" }
Expand Down

0 comments on commit 710fca4

Please sign in to comment.