Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 0 additions & 65 deletions app/build.gradle

This file was deleted.

67 changes: 67 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
import java.io.FileInputStream
import java.io.FileNotFoundException
import java.util.Properties

plugins {
alias(libs.plugins.android.application)
alias(libs.plugins.oss.licenses.plugin)
alias(libs.plugins.ktfmt)
alias(libs.plugins.kotlin.android)
}

val keystorePropertiesFile = rootProject.file("keystore.properties")
val keystoreProperties = Properties()

try {
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
} catch (_: FileNotFoundException) {
logger.warn("keystore.properties not found")
}

android {
namespace = "com.github.shingyx.boomswitch"
signingConfigs {
create("release") {
storeFile = rootProject.file(keystoreProperties.getProperty("storeFile") ?: "default.jks")
storePassword = keystoreProperties.getProperty("storePassword")
keyAlias = keystoreProperties.getProperty("keyAlias")
keyPassword = keystoreProperties.getProperty("keyPassword")
}
}
compileSdk = 36
defaultConfig {
applicationId = "com.github.shingyx.boomswitch"
minSdk = 23
targetSdk = 36
versionCode = 13
versionName = "1.9"
}
buildTypes {
getByName("debug") {
applicationIdSuffix = ".dev"
versionNameSuffix = "-dev"
}
getByName("release") {
isMinifyEnabled = true
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"))
signingConfig = signingConfigs["release"]
}
}
buildFeatures {
buildConfig = true
viewBinding = true
}
kotlin { jvmToolchain(21) }
}

ktfmt { googleStyle() }

dependencies {
implementation(libs.androidx.appcompat)
implementation(libs.androidx.constraintlayout)
implementation(libs.kotlin.stdlib)
implementation(libs.kotlinx.coroutines.android)
implementation(libs.material)
implementation(libs.oss.licenses)
implementation(libs.timber)
}
27 changes: 0 additions & 27 deletions build.gradle

This file was deleted.

6 changes: 6 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
plugins {
alias(libs.plugins.android.application) apply false
alias(libs.plugins.kotlin.android) apply false
alias(libs.plugins.ktfmt) apply false
alias(libs.plugins.oss.licenses.plugin) apply false
}
26 changes: 26 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[versions]
agp = "8.12.1"
appcompat = "1.7.1"
constraintlayout = "2.2.1"
kotlin = "2.2.10"
kotlinxCoroutines = "1.10.2"
ktfmt = "0.23.0"
material = "1.12.0"
ossLicenses = "17.2.2"
ossLicensesPlugin = "0.10.7"
timber = "5.0.1"

[libraries]
androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "appcompat" }
androidx-constraintlayout = { module = "androidx.constraintlayout:constraintlayout", version.ref = "constraintlayout" }
kotlin-stdlib = { module = "org.jetbrains.kotlin:kotlin-stdlib", version.ref = "kotlin" }
kotlinx-coroutines-android = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "kotlinxCoroutines" }
material = { module = "com.google.android.material:material", version.ref = "material" }
oss-licenses = { module = "com.google.android.gms:play-services-oss-licenses", version.ref = "ossLicenses" }
timber = { module = "com.jakewharton.timber:timber", version.ref = "timber" }

[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
ktfmt = { id = "com.ncorti.ktfmt.gradle", version.ref = "ktfmt" }
oss-licenses-plugin = { id = "com.google.android.gms.oss-licenses-plugin", version.ref = "ossLicensesPlugin" }
1 change: 0 additions & 1 deletion settings.gradle

This file was deleted.

24 changes: 24 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
pluginManagement {
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
resolutionStrategy {
eachPlugin {
if (requested.id.id == "com.google.android.gms.oss-licenses-plugin") {
useModule("com.google.android.gms:oss-licenses-plugin:${requested.version}")
}
}
}
}

dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
}
}

include(":app")