mirror of
https://git.selfprivacy.org/kherel/selfprivacy.org.app.git
synced 2024-11-19 15:19:14 +00:00
101 lines
2 KiB
Groovy
101 lines
2 KiB
Groovy
plugins {
|
|
id "com.android.application"
|
|
id "kotlin-android"
|
|
id "dev.flutter.flutter-gradle-plugin"
|
|
}
|
|
|
|
|
|
def localProperties = new Properties()
|
|
def localPropertiesFile = rootProject.file('local.properties')
|
|
if (localPropertiesFile.exists()) {
|
|
localPropertiesFile.withReader('UTF-8') { reader ->
|
|
localProperties.load(reader)
|
|
}
|
|
}
|
|
|
|
|
|
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
|
|
if (flutterVersionCode == null) {
|
|
flutterVersionCode = '1'
|
|
}
|
|
|
|
def flutterVersionName = localProperties.getProperty('flutter.versionName')
|
|
if (flutterVersionName == null) {
|
|
flutterVersionName = '1.0'
|
|
}
|
|
|
|
android {
|
|
namespace 'org.selfprivacy.app'
|
|
compileSdkVersion flutter.compileSdkVersion
|
|
ndkVersion flutter.ndkVersion
|
|
|
|
sourceSets {
|
|
main.java.srcDirs += 'src/main/kotlin'
|
|
}
|
|
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_1_8
|
|
targetCompatibility JavaVersion.VERSION_1_8
|
|
}
|
|
|
|
kotlinOptions {
|
|
jvmTarget = '1.8'
|
|
}
|
|
|
|
sourceSets {
|
|
main.java.srcDirs += 'src/main/kotlin'
|
|
}
|
|
|
|
lintOptions {
|
|
disable 'InvalidPackage'
|
|
}
|
|
|
|
defaultConfig {
|
|
applicationId "org.selfprivacy.app"
|
|
minSdkVersion 21
|
|
targetSdkVersion 34
|
|
compileSdkVersion 34
|
|
versionCode flutterVersionCode.toInteger()
|
|
versionName flutterVersionName
|
|
}
|
|
|
|
buildTypes {
|
|
debug {
|
|
|
|
}
|
|
profile {
|
|
|
|
}
|
|
release {
|
|
|
|
}
|
|
}
|
|
buildFeatures {
|
|
flavorDimensions = ["default"]
|
|
}
|
|
|
|
|
|
productFlavors {
|
|
fdroid {
|
|
dimension 'default'
|
|
applicationId "pro.kherel.selfprivacy"
|
|
}
|
|
production {
|
|
dimension 'default'
|
|
}
|
|
nightly {
|
|
dimension 'default'
|
|
applicationIdSuffix ".nightly"
|
|
versionCode project.getVersionCode()
|
|
versionName "nightly-" + project.getVersionCode()
|
|
}
|
|
}
|
|
}
|
|
|
|
flutter {
|
|
source '../..'
|
|
}
|
|
|
|
dependencies {}
|
|
|