Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 896ee5b9 authored by Vincent Bourgmayer's avatar Vincent Bourgmayer
Browse files

Merge branch '318-o-fixVersionNumber' into 'v1-oreo'

update version number and apk's name

See merge request !138
parents ef059ec6 f7293044
Loading
Loading
Loading
Loading
Loading
+5 −9
Original line number Diff line number Diff line
@@ -2,12 +2,9 @@
import java.text.SimpleDateFormat;
apply plugin: 'com.android.application'
def versionMajor = 1
def versionMinor = 0
def versionPatch = 0

def buildTime() {
    def df = new SimpleDateFormat("yy-MM-dd'T'HHmm") // you can change it
    df.setTimeZone(TimeZone.getTimeZone("UTC"))
    return df.format(new Date())
}

def getTestProp(String propName) {
    def result = ""
@@ -27,10 +24,9 @@ android {
    defaultConfig {
        applicationId "foundation.e.drive"
        minSdkVersion 26
        versionCode 1
        //versionName "1.0"
        versionName "beta-${versionMajor}-build-o-${buildTime()}"
        setProperty("archivesBaseName", "$applicationId.$versionName")
        versionCode versionMajor * 1000000 + versionMinor * 1000 + versionPatch
        versionName "${versionMajor}.${versionMinor}.${versionPatch}"
        setProperty("archivesBaseName", "eDrive-$versionName")
        buildConfigField "String", "testAccountName", "\""+getTestProp("testAccountName")+"\""
        buildConfigField "String", "testAccountPWd", "\""+getTestProp("testAccountPwd")+"\""
        buildConfigField "String", "testServerUrl", "\""+getTestProp("testServerUrl")+"\""