You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

78 lines
2.5 KiB

import java.text.DateFormat
import java.text.SimpleDateFormat
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
}
def getDateTime() {
// DateFormat df = new SimpleDateFormat("yyyyMMddHHmm")
DateFormat df = new SimpleDateFormat("yyMMdd")
return df.format(new Date())
}
android {
namespace 'com.techscan.yonsuite'
compileSdk rootProject.ext.version.compileSdkVersion
defaultConfig {
applicationId "com.techscan.yonsuite"
minSdk rootProject.ext.version.minSdkVersion
targetSdk rootProject.ext.version.targetSdkVersion
versionCode rootProject.ext.version.versionCode
versionName rootProject.ext.version.versionName
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled true
//shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
debug {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
applicationVariants.all { variant ->
variant.outputs.all { output ->
def outputFile = output.outputFile
def fileName
if (outputFile != null && outputFile.name.endsWith('.apk')) {
if (variant.buildType.name == 'release') {
fileName = "techscan_ysbarcode_${defaultConfig.versionName}.apk"
} else if (variant.buildType.name == 'debug') {
fileName = "ysbarcode_${defaultConfig.versionName}_${getDateTime()}_debug.apk"
}
outputFileName = fileName
}
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(path: ':module_base')
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.8.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation "androidx.core:core-splashscreen:1.0.1"
if (!Boolean.valueOf(rootProject.ext.isModule)) {
implementation project(path: ':module_login')
implementation project(path: ':module_main')
implementation project(path: ':module_allfunction')
}
}