mirror of
https://github.com/greenart7c3/Amber.git
synced 2026-10-05 19:08:23 +00:00
253 lines
6.6 KiB
Groovy
253 lines
6.6 KiB
Groovy
plugins {
|
|
alias(libs.plugins.androidApplication)
|
|
alias(libs.plugins.gradle.ktlint) version(libs.versions.ktlint)
|
|
alias(libs.plugins.kotlin.ksp) version(libs.versions.ksp)
|
|
alias(libs.plugins.jetbrainsComposeCompiler)
|
|
}
|
|
|
|
android {
|
|
namespace = 'com.greenart7c3.nostrsigner'
|
|
compileSdk = 36
|
|
|
|
defaultConfig {
|
|
applicationId "com.greenart7c3.nostrsigner"
|
|
minSdk 26
|
|
versionCode 173
|
|
versionName "4.1.2-pre1"
|
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
|
vectorDrawables {
|
|
useSupportLibrary = true
|
|
}
|
|
resourceConfigurations += [
|
|
'bn-rBD',
|
|
'cs',
|
|
'cy-rGB',
|
|
'da-rDK',
|
|
'de',
|
|
'el-rGR',
|
|
'en-rGB',
|
|
'eo',
|
|
'es',
|
|
'es-rES',
|
|
'es-rMX',
|
|
'es-rUS',
|
|
'et-rEE',
|
|
'fa',
|
|
'fi-rFI',
|
|
'fo-rFO',
|
|
'fr',
|
|
'fr-rCA',
|
|
'gu-rIN',
|
|
'hi-rIN',
|
|
'hr-rHR',
|
|
'hu',
|
|
'in',
|
|
'in-rID',
|
|
'it-rIT',
|
|
'iw-rIL',
|
|
'ja',
|
|
'kk-rKZ',
|
|
'ko-rKR',
|
|
'ks-rIN',
|
|
'ku-rTR',
|
|
'lt-rLT',
|
|
'ne-rNP',
|
|
'nl',
|
|
'nl-rBE',
|
|
'pcm-rNG',
|
|
'pl-rPL',
|
|
'pt-rBR',
|
|
'pt-rPT',
|
|
'ru',
|
|
'ru-rUA',
|
|
'sa-rIN',
|
|
'sl-rSI',
|
|
'so-rSO',
|
|
'sr-rSP',
|
|
'ss-rZA',
|
|
'sv-rSE',
|
|
'sw-rKE',
|
|
'sw-rTZ',
|
|
'ta',
|
|
'th',
|
|
'tr',
|
|
'uk',
|
|
'ur-rIN',
|
|
'uz-rUZ',
|
|
'vi-rVN',
|
|
'zh',
|
|
'zh-rCN',
|
|
'zh-rHK',
|
|
'zh-rSG',
|
|
'zh-rTW'
|
|
]
|
|
lint {
|
|
disable 'MissingTranslation'
|
|
}
|
|
}
|
|
|
|
ksp {
|
|
arg("room.schemaLocation", "$projectDir/schemas")
|
|
}
|
|
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_21
|
|
targetCompatibility JavaVersion.VERSION_21
|
|
}
|
|
|
|
if (System.getenv('SIGN_RELEASE')) {
|
|
def keystorePropertiesFile = rootProject.file("keystore.properties")
|
|
def keystoreProperties = new Properties()
|
|
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
|
|
|
signingConfigs {
|
|
release {
|
|
keyAlias keystoreProperties['keyAlias']
|
|
keyPassword keystoreProperties['keyPassword']
|
|
storeFile file(keystoreProperties['storeFile'])
|
|
storePassword keystoreProperties['storePassword']
|
|
}
|
|
}
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
if (System.getenv('SIGN_RELEASE')) {
|
|
signingConfig signingConfigs.release
|
|
}
|
|
proguardFiles getDefaultProguardFile("proguard-android-optimize.txt"), 'proguard-rules.pro'
|
|
minifyEnabled true
|
|
resValue "string", "app_name", "@string/app_name_release"
|
|
}
|
|
debug {
|
|
applicationIdSuffix '.debug'
|
|
versionNameSuffix '-DEBUG'
|
|
resValue "string", "app_name", "@string/app_name_debug"
|
|
}
|
|
}
|
|
|
|
flavorDimensions += "version"
|
|
|
|
productFlavors {
|
|
register("free") {
|
|
getIsDefault().set(true)
|
|
dimension = "version"
|
|
}
|
|
register("offline") {
|
|
dimension = "version"
|
|
}
|
|
}
|
|
|
|
splits {
|
|
abi {
|
|
enable = true
|
|
reset()
|
|
include "x86", "x86_64", "arm64-v8a", "armeabi-v7a"
|
|
universalApk = true
|
|
}
|
|
}
|
|
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_21
|
|
targetCompatibility JavaVersion.VERSION_21
|
|
}
|
|
|
|
buildFeatures {
|
|
compose = true
|
|
buildConfig = true
|
|
resValues = true
|
|
}
|
|
|
|
packagingOptions {
|
|
resources {
|
|
excludes += '/META-INF/{AL2.0,LGPL2.1}'
|
|
excludes +='META-INF/versions/9/OSGI-INF/MANIFEST.MF'
|
|
}
|
|
}
|
|
}
|
|
|
|
composeCompiler {
|
|
reportsDestination = layout.buildDirectory.dir("compose_compiler")
|
|
}
|
|
|
|
|
|
dependencies {
|
|
implementation(libs.quartz) {
|
|
exclude group: 'net.java.dev.jna'
|
|
}
|
|
implementation(libs.jna) {
|
|
artifact { type = "aar" }
|
|
}
|
|
|
|
implementation libs.core.ktx
|
|
implementation libs.activity.compose
|
|
implementation libs.ui
|
|
implementation libs.ui.tooling.preview
|
|
|
|
// Navigation
|
|
implementation libs.navigation.compose
|
|
|
|
implementation libs.material3
|
|
implementation libs.material.icons.extended
|
|
|
|
implementation libs.appcompat
|
|
implementation libs.work.runtime.ktx
|
|
implementation libs.material3.window
|
|
implementation libs.paging.common
|
|
implementation libs.paging.compose
|
|
implementation libs.paging.runtime
|
|
|
|
testImplementation libs.junit
|
|
androidTestImplementation libs.ext.junit
|
|
androidTestImplementation libs.espresso.core
|
|
androidTestImplementation libs.ui.test.junit4
|
|
debugImplementation libs.ui.tooling
|
|
debugImplementation libs.ui.test.manifest
|
|
|
|
implementation libs.security.crypto.ktx
|
|
|
|
// Lifecycle
|
|
implementation libs.lifecycle.runtime.compose
|
|
implementation libs.lifecycle.viewmodel.compose
|
|
implementation libs.lifecycle.runtime.ktx
|
|
|
|
// For QR generation
|
|
implementation libs.core
|
|
implementation libs.zxing.android.embedded
|
|
|
|
// Markdown (With fix for full-image bleeds)
|
|
implementation(libs.richtext.ui)
|
|
implementation(libs.richtext.ui.material3)
|
|
implementation(libs.richtext.commonmark)
|
|
|
|
// Biometrics
|
|
implementation libs.biometric.ktx
|
|
|
|
ksp(libs.room.compiler)
|
|
implementation(libs.room.ktx)
|
|
implementation(libs.room.runtime)
|
|
implementation(libs.room.paging)
|
|
|
|
freeImplementation libs.okhttp
|
|
freeImplementation libs.okhttpCoroutines
|
|
|
|
// Load images from the web.
|
|
implementation libs.coil.compose
|
|
// view gifs
|
|
implementation libs.coil.gif
|
|
// view svgs
|
|
implementation libs.coil.svg
|
|
// enables network for coil
|
|
implementation libs.coil.okhttp
|
|
implementation libs.okhttpCoroutines
|
|
|
|
implementation libs.storage
|
|
|
|
implementation libs.datastore.preferences
|
|
implementation libs.security.crypto
|
|
|
|
implementation libs.lifecycle.process
|
|
implementation libs.kotlinx.collections.immutable
|
|
}
|