build: name output files & minor refactor

This commit is contained in:
oSumAtrIX 2023-01-02 02:58:20 +01:00 committed by GitHub
commit bc635a79c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 19 additions and 24 deletions

View File

@ -8,29 +8,31 @@ plugins {
android { android {
compileSdk = 33 compileSdk = 33
buildToolsVersion = "33.0.0" buildToolsVersion = "33.0.1"
namespace = "app.revanced.integrations" namespace = "app.revanced.integrations"
defaultConfig { defaultConfig {
applicationId = "app.revanced.integrations" applicationId = "app.revanced.integrations"
minSdk = 23 minSdk = 23
targetSdk = 33 targetSdk = 33
versionCode = 1
versionName = "1.0"
multiDexEnabled = false multiDexEnabled = false
versionName = project.version as String
val properties = Properties()
if (rootProject.file("local.properties").exists()) {
properties.load(FileInputStream(rootProject.file("local.properties")))
}
buildConfigField("String", "YT_API_KEY", "\"${properties.getProperty("youtubeAPIKey", "")}\"")
} }
buildTypes { buildTypes {
release { release {
isMinifyEnabled = true isMinifyEnabled = true
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro") proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
applicationVariants.all {
outputs.all {
this as com.android.build.gradle.internal.api.ApkVariantOutputImpl
outputFileName = "${rootProject.name}-$versionName.apk"
}
} }
} }
compileOptions { compileOptions {

View File

@ -13,12 +13,6 @@ buildscript {
} }
} }
// Tracking issue https://github.com/semantic-release/semantic-release/issues/963
tasks.register("publish", DefaultTask::class) {
group = "publish"
description = "Dummy publish to pass the verification phase of the gradle-semantic-release-plugin"
}
tasks.register("clean", Delete::class) { tasks.register("clean", Delete::class) {
delete(rootProject.buildDir) delete(rootProject.buildDir)
} }

View File

@ -4,11 +4,12 @@ plugins {
android { android {
namespace = "app.revanced.dummy" namespace = "app.revanced.dummy"
compileSdk = 32 compileSdk = 33
buildToolsVersion = "33.0.1"
defaultConfig { defaultConfig {
minSdk = 26 minSdk = 23
targetSdk = 32 targetSdk = 33
} }
buildTypes { buildTypes {
@ -25,6 +26,3 @@ android {
targetCompatibility = JavaVersion.VERSION_11 targetCompatibility = JavaVersion.VERSION_11
} }
} }
dependencies {
}

View File

@ -8,4 +8,5 @@ dependencyResolutionManagement {
} }
include(":app") include(":app")
include(":dummy") include(":dummy")
rootProject.name = "integrations"
rootProject.name = "revanced-integrations"