| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- plugins {
- id 'com.android.application'
- id 'org.jetbrains.kotlin.android'
- }
- def getVersionCode = { ->
- try {
- def stdout = new ByteArrayOutputStream()
- exec {
- commandLine 'git', 'rev-list', '--first-parent', '--count', 'master'
- standardOutput = stdout
- }
- return Integer.parseInt(stdout.toString().trim())
- }
- catch (ignored) {
- return -1;
- }
- }
- def getVersionName = { ->
- try {
- def stdout = new ByteArrayOutputStream()
- exec {
- commandLine 'git', 'describe', '--always', '--tags', '--dirty'
- standardOutput = stdout
- }
- return stdout.toString().trim()
- }
- catch (ignored) {
- return null;
- }
- }
- // Signing config, mainly intended for debug builds
- def keystorePropertiesFile = rootProject.file("keystore.properties");
- def keystoreProperties = new Properties()
- keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
- android {
- compileSdk 34
- defaultConfig {
- applicationId "im.angry.openeuicc"
- minSdk 30
- targetSdk 31
- versionCode getVersionCode()
- versionName getVersionName()
- testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
- }
- signingConfigs {
- config {
- storeFile file(keystoreProperties['storeFile'])
- storePassword keystoreProperties['storePassword']
- keyAlias keystoreProperties['keyAlias']
- keyPassword keystoreProperties['keyPassword']
- }
- }
- buildTypes {
- release {
- minifyEnabled false
- proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
- signingConfig signingConfigs.config
- }
- debug {
- signingConfig signingConfigs.config
- }
- }
- compileOptions {
- sourceCompatibility JavaVersion.VERSION_1_8
- targetCompatibility JavaVersion.VERSION_1_8
- }
- kotlinOptions {
- jvmTarget = '1.8'
- }
- namespace 'im.angry.openeuicc'
- }
- dependencies {
- compileOnly project(':libs:hidden-apis-stub')
- implementation project(':libs:hidden-apis-shim')
- implementation project(":libs:lpac-jni")
- implementation 'androidx.core:core-ktx:1.12.0'
- implementation 'androidx.appcompat:appcompat:1.6.1'
- implementation 'com.google.android.material:material:1.10.0'
- implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
- implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.6.2'
- implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
- implementation "androidx.cardview:cardview:1.0.0"
- implementation 'com.journeyapps:zxing-android-embedded:4.3.0'
- testImplementation 'junit:junit:4.13.2'
- androidTestImplementation 'androidx.test.ext:junit:1.1.3'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
- }
|