Skip to content

Commit

Permalink
Fix version code: Version code must be in build.gradle.kts for f-droi…
Browse files Browse the repository at this point in the history
…d version checker to work
  • Loading branch information
bailuk committed Apr 28, 2024
1 parent 258f466 commit 828b825
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
4 changes: 3 additions & 1 deletion aat-android/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ android {
defaultConfig {
minSdk = 22
targetSdk = 33
versionCode = 37

// Version Code can not be taken from from variable (f-droid version checker fail)
versionCode = 38
versionName = appVersionName
applicationId = appId
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,7 @@ import ch.bailu.aat_lib.app.AppConfig

class AndroidAppConfig : AppConfig() {
override val isRelease = !BuildConfig.DEBUG

// Version Code can not be taken from from variable (f-droid version checker fail)
override val appVersionCode = BuildConfig.VERSION_CODE
}
1 change: 0 additions & 1 deletion aat-lib/src/main/java/ch/bailu/aat_lib/Configuration.kt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ object Configuration {
const val appContact = "aat@bailu.ch"
const val mapsForgeVersion = "0.20.0"
const val appVersionName = "v1.25"
const val appVersionCode = "38"
const val focVersion = "1.3"
const val appCopyright = "© 2011-2024 Lukas Bai, GNU GPLv3 or later\n© Map and data OSM contributors ODbL 1.0"
const val appId = "ch.bailu.aat"
Expand Down
2 changes: 1 addition & 1 deletion aat-lib/src/main/java/ch/bailu/aat_lib/app/AppConfig.kt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ abstract class AppConfig : WithStatusText {
open val appVersionName: String
get() = Configuration.appVersionName
open val appVersionCode: Int
get() = Configuration.appVersionCode.toInt()
get() = 0
val appWebsite: String
get() = Configuration.appWebsite
val appCopyright: String
Expand Down
1 change: 0 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ appLongName=AAT Activity Tracker
appContact=aat@bailu.ch
appVersionName=v1.25
appWebsite=https://github.com/bailuk/AAT
appVersionCode=38
appId=ch.bailu.aat

appCopyright=© 2011-2024 Lukas Bai, GNU GPLv3 or later\\n© Map and data OSM contributors ODbL 1.0

0 comments on commit 828b825

Please sign in to comment.