[gradle] Fix build (#246)

This commit is contained in:
LoveSy 2021-03-02 03:40:18 +08:00 committed by GitHub
parent 5b49351b7e
commit 5694e459a3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View File

@ -84,9 +84,9 @@ android {
isShrinkResources = false
}
}
applicationVariants.forEach { variant ->
variant.outputs.map { it as BaseVariantOutputImpl }.forEach { output ->
output.outputFileName = "LSPosedManager-${defaultConfig.versionName}-${defaultConfig.versionCode}-${variant.buildType.name}.apk"
applicationVariants.all {
outputs.map { it as BaseVariantOutputImpl }.forEach { output ->
output.outputFileName = "LSPosedManager-${defaultConfig.versionName}-${defaultConfig.versionCode}-${buildType.name}.apk"
}
}
}

View File

@ -174,8 +174,8 @@ afterEvaluate {
val excludeList = arrayOf("util_functions.sh")
doLast {
val dexOutPath = if (variant.name.contains("release"))
"buildDir/intermediates/dex/variantLowered/minify${variantCapped}WithR8" else
"buildDir/intermediates/dex/variantLowered/mergeDex$variantCapped"
"$buildDir/intermediates/dex/$variantLowered/minify${variantCapped}WithR8" else
"$buildDir/intermediates/dex/$variantLowered/mergeDex$variantCapped"
copy {
from(dexOutPath) {
rename("classes.dex", "lspd.dex")