diff --git a/android/build.gradle.kts b/android/build.gradle.kts index fa5ffaae..a4d785f7 100644 --- a/android/build.gradle.kts +++ b/android/build.gradle.kts @@ -40,10 +40,16 @@ plugins { androidGitVersion { prefix = "v" codeFormat = "MNPBB" - baseCode = 3030000 } -thanoxVersionCode = androidGitVersion.code() +// Make sure new code > released. +val legacyCodeBase = 2000000 +// 2000.1.1 millis +val startOf2000 = 946684800000L +// +1 10min +val versionCodeByTime = + ((System.currentTimeMillis() - startOf2000) / 1000 / 60 / 10).toInt() + legacyCodeBase +thanoxVersionCode = versionCodeByTime thanoxVersionName = androidGitVersion.name() printVersions()