星火管控
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.

build.gradle.kts 2.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. @file:Suppress("CAST_NEVER_SUCCEEDS")
  2. @Suppress("DSL_SCOPE_VIOLATION") // TODO: Remove once KTIJ-19369 is fixed
  3. plugins {
  4. alias(libs.plugins.androidApplication)
  5. alias(libs.plugins.kotlinAndroid)
  6. }
  7. android {
  8. namespace = "com.xhly.manageapp"
  9. compileSdk = 34
  10. defaultConfig {
  11. applicationId = "com.xhly.manageapp"
  12. minSdk = 24
  13. targetSdk = 30
  14. versionCode = 1
  15. versionName = "1.0"
  16. testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
  17. vectorDrawables {
  18. useSupportLibrary = true
  19. }
  20. }
  21. viewBinding{
  22. enable=true
  23. }
  24. signingConfigs {
  25. create("keystore") {
  26. keyAlias = "xinghuo"
  27. keyPassword = "xhkjedu"
  28. storeFile = file("xinghuo.keystore")
  29. storePassword = "xhkjedu"
  30. }
  31. }
  32. buildTypes {
  33. /* release {
  34. isMinifyEnabled = false
  35. proguardFiles(
  36. getDefaultProguardFile("proguard-android-optimize.txt"),
  37. "proguard-rules.pro"
  38. )
  39. }*/
  40. val signConfig=signingConfigs.getByName("keystore")
  41. getByName("release") {
  42. isMinifyEnabled = false
  43. proguardFiles(
  44. getDefaultProguardFile("proguard-android-optimize.txt"),
  45. "proguard-rules.pro"
  46. )
  47. signingConfig=signConfig
  48. }
  49. getByName("debug") {
  50. isMinifyEnabled = false
  51. proguardFiles(
  52. getDefaultProguardFile("proguard-android-optimize.txt"),
  53. "proguard-rules.pro"
  54. )
  55. signingConfig=signConfig
  56. }
  57. }
  58. compileOptions {
  59. sourceCompatibility = JavaVersion.VERSION_1_8
  60. targetCompatibility = JavaVersion.VERSION_1_8
  61. }
  62. kotlinOptions {
  63. jvmTarget = "1.8"
  64. }
  65. buildFeatures {
  66. compose = true
  67. }
  68. composeOptions {
  69. kotlinCompilerExtensionVersion = "1.4.3"
  70. }
  71. packaging {
  72. resources {
  73. excludes += "/META-INF/{AL2.0,LGPL2.1}"
  74. }
  75. }
  76. lint {
  77. abortOnError=false
  78. }
  79. }
  80. dependencies {
  81. implementation(libs.core.ktx)
  82. implementation(libs.lifecycle.runtime.ktx)
  83. implementation(libs.activity.compose)
  84. implementation(platform(libs.compose.bom))
  85. implementation(libs.ui)
  86. implementation(libs.ui.graphics)
  87. implementation(libs.ui.tooling.preview)
  88. implementation(libs.material3)
  89. implementation(libs.appcompat)
  90. implementation(libs.androidx.recyclerview)
  91. implementation(project(mapOf("path" to ":websocket")))
  92. implementation(libs.androidx.cardview)
  93. testImplementation(libs.junit)
  94. androidTestImplementation(libs.androidx.test.ext.junit)
  95. androidTestImplementation(libs.espresso.core)
  96. androidTestImplementation(platform(libs.compose.bom))
  97. androidTestImplementation(libs.ui.test.junit4)
  98. debugImplementation(libs.ui.tooling)
  99. debugImplementation(libs.ui.test.manifest)
  100. }