Add version management with auto-bump script
Version is tracked in version.properties and read by build.gradle.kts. Run ./bump-version.sh [major|minor|patch] before release builds. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
7979ebd029
commit
52af9f6047
3 changed files with 67 additions and 2 deletions
|
|
@ -14,6 +14,15 @@ val keystoreProperties = Properties().apply {
|
|||
}
|
||||
}
|
||||
|
||||
// Load version from version.properties
|
||||
val versionProperties = Properties().apply {
|
||||
load(rootProject.file("version.properties").inputStream())
|
||||
}
|
||||
val vMajor = versionProperties["versionMajor"].toString().toInt()
|
||||
val vMinor = versionProperties["versionMinor"].toString().toInt()
|
||||
val vPatch = versionProperties["versionPatch"].toString().toInt()
|
||||
val vCode = versionProperties["versionCode"].toString().toInt()
|
||||
|
||||
android {
|
||||
namespace = "no.naiv.tiltshift"
|
||||
compileSdk = 35
|
||||
|
|
@ -34,8 +43,8 @@ android {
|
|||
applicationId = "no.naiv.tiltshift"
|
||||
minSdk = 35
|
||||
targetSdk = 35
|
||||
versionCode = 1
|
||||
versionName = "1.0.0"
|
||||
versionCode = vCode
|
||||
versionName = "$vMajor.$vMinor.$vPatch"
|
||||
|
||||
vectorDrawables {
|
||||
useSupportLibrary = true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue