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.
88 lines
2.4 KiB
88 lines
2.4 KiB
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
|
|
|
plugins {
|
|
alias(libs.plugins.android.application)
|
|
alias(libs.plugins.kotlin.android)
|
|
}
|
|
|
|
android {
|
|
namespace 'com.iflytop.profilometer'
|
|
compileSdk 35
|
|
|
|
defaultConfig {
|
|
applicationId "com.iflytop.profilometer"
|
|
minSdk 26
|
|
targetSdk 35
|
|
versionCode 1
|
|
versionName "1.0"
|
|
|
|
// 指定应用内部版本号
|
|
versionCode 2
|
|
// 指定展示给用户的版本号
|
|
versionName "1.1.2"
|
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
|
}
|
|
|
|
signingConfigs {
|
|
release {
|
|
// 将下面信息替换为你的 keystore 文件路径和相关密码
|
|
storeFile file("keystore/release.keystore")
|
|
storePassword "iflytop#110011"
|
|
keyAlias "iflytop"
|
|
keyPassword "iflytop#110011"
|
|
}
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
minifyEnabled true// 开启混淆和压缩
|
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
|
signingConfig signingConfigs.release// 指定 release 使用的签名配置
|
|
}
|
|
}
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_21
|
|
targetCompatibility JavaVersion.VERSION_21
|
|
}
|
|
|
|
packagingOptions {
|
|
exclude 'META-INF/INDEX.LIST'
|
|
}
|
|
}
|
|
|
|
android.applicationVariants.configureEach { variant ->
|
|
variant.outputs.configureEach { output ->
|
|
def buildType = variant.buildType.name
|
|
outputFileName = "廓形仪-${buildType}-v${variant.versionName}.apk"
|
|
}
|
|
}
|
|
|
|
tasks.withType(KotlinCompile).configureEach {
|
|
kotlinOptions {
|
|
jvmTarget = "21"
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation libs.appcompat
|
|
implementation libs.material
|
|
implementation libs.activity
|
|
implementation libs.constraintlayout
|
|
|
|
implementation libs.gson
|
|
implementation libs.reflections
|
|
implementation libs.kotlin.stdlib
|
|
implementation libs.ktor.server.core
|
|
implementation libs.ktor.server.cors
|
|
implementation libs.ktor.server.cio
|
|
implementation libs.ktor.server.websockets
|
|
implementation libs.ktor.server.content.negotiation
|
|
implementation libs.ktor.serialization.kotlinx.json
|
|
implementation libs.hutool.json
|
|
|
|
testImplementation libs.junit
|
|
androidTestImplementation libs.ext.junit
|
|
androidTestImplementation libs.espresso.core
|
|
|
|
}
|