DEADSOFTWARE

Update version
[cavedroid.git] / android / build.gradle
index 70bf45521744cf0d2ea637707ccbe951587953b1..a01eaab71bf6756ac012597044f128ecd88ab35f 100644 (file)
@@ -1,6 +1,14 @@
+plugins {
+    id "kotlin-android"
+}
+
+def keystorePropertiesFile = rootProject.file("keystore.properties")
+def keystoreProperties = new Properties()
+keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
+
 android {
-    buildToolsVersion "28.0.3"
-    compileSdkVersion 29
+    namespace "ru.deadsoftware.cavedroid"
+    compileSdkVersion 34
     sourceSets {
         main {
             manifest.srcFile 'AndroidManifest.xml'
@@ -15,24 +23,48 @@ android {
             res.srcDirs = ['debug/res']
         }
     }
+    compileOptions {
+        sourceCompatibility 17
+        targetCompatibility 17
+    }
     packagingOptions {
         exclude 'META-INF/robovm/ios/robovm.xml'
     }
     defaultConfig {
         applicationId "ru.deadsoftware.cavedroid"
-        minSdkVersion 14
-        targetSdkVersion 29
-        versionCode 10
-        versionName "alpha0.4"
+        minSdkVersion 24
+        targetSdkVersion 34
+        versionCode 18
+        versionName "alpha0.6.1"
+    }
+    applicationVariants.all { variant ->
+        variant.outputs.all {
+            outputFileName = "android-${versionName}.apk"
+        }
     }
+
+    signingConfigs {
+        release_config {
+            storeFile file(keystoreProperties['releaseKeystorePath'])
+            storePassword keystoreProperties['releaseKeystorePassword']
+            keyAlias keystoreProperties['releaseKeyAlias']
+            keyPassword keystoreProperties['releaseKeyPassword']
+        }
+    }
+
     buildTypes {
         release {
             minifyEnabled false
+            signingConfig signingConfigs.release_config
         }
         debug {
             applicationIdSuffix ".debug"
         }
     }
+    buildFeatures {
+        buildConfig true
+    }
+
 }