mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-25 14:37:38 +00:00
41 lines
1.0 KiB
Plaintext
41 lines
1.0 KiB
Plaintext
plugins {
|
|
id("com.android.application")
|
|
}
|
|
|
|
android {
|
|
val canary = !Config.version.contains(".")
|
|
|
|
val url = Config["DEV_CHANNEL"] ?: if (canary) null
|
|
else "https://cdn.jsdelivr.net/gh/topjohnwu/magisk-files@${Config.version}/app-release.apk"
|
|
|
|
defaultConfig {
|
|
applicationId = "com.topjohnwu.magisk"
|
|
versionCode = 1
|
|
versionName = Config.version
|
|
buildConfigField("int", "STUB_VERSION", Config.stubVersion)
|
|
buildConfigField("String", "APK_URL", url?.let { "\"$it\"" } ?: "null" )
|
|
}
|
|
|
|
buildTypes {
|
|
getByName("release") {
|
|
isMinifyEnabled = true
|
|
isShrinkResources = false
|
|
proguardFiles("proguard-rules.pro")
|
|
}
|
|
}
|
|
|
|
androidResources {
|
|
additionalParameters("--package-id", "0x80")
|
|
}
|
|
|
|
dependenciesInfo {
|
|
includeInApk = false
|
|
includeInBundle = false
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.jar"))))
|
|
implementation(project(":app:shared"))
|
|
}
|