Skip to content

Commit

Permalink
add hardcoded version info for f-droid bot
Browse files Browse the repository at this point in the history
  • Loading branch information
oversecio authored Feb 3, 2019
1 parent 695672a commit 8b091ac
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,21 @@ android {
applicationId "io.oversec.one"
minSdkVersion 21
targetSdkVersion 28

versionCode = androidGitVersion.code()
versionName = androidGitVersion.name()
if (isFdroidBuild) {
versionName = fdroidVersionName
versionCode = fdroidVersionCode

//hardcoded for F-droid bot
versionCode = 1005010
versionName = "1.5.10"

//still need to make sure this is in sync with the git tags
def versionCodeFromGit = androidGitVersion.code()
if (versionCode!=versionCodeFromGit) {
throw new Exception(String.format("Version Code Mismatch, %d <-> %d\nPlease update hardcoded versionCode/versionName",versionCode,versionCodeFromGit))
}

// if (isFdroidBuild) {
// versionName = fdroidVersionName
// versionCode = fdroidVersionCode
// }
buildConfigField "java.lang.Boolean", "IS_FRDOID", "new Boolean("+isFdroidBuild+")"
}

Expand Down

0 comments on commit 8b091ac

Please sign in to comment.