build.gradle.kts 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. plugins {
  2. id("com.android.application")
  3. id("org.jetbrains.kotlin.android")
  4. kotlin("kapt") version Sdk.kotlin
  5. }
  6. android {
  7. compileSdk = Sdk.compileSdk
  8. defaultConfig {
  9. applicationId = "com.ys.bdtp.adm"
  10. minSdk = Sdk.minSdk
  11. targetSdk = Sdk.targetSdk
  12. versionCode = Sdk.versionCode
  13. versionName = Sdk.versionName
  14. testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
  15. vectorDrawables {
  16. useSupportLibrary = true
  17. }
  18. }
  19. buildTypes {
  20. release {
  21. isMinifyEnabled = false
  22. proguardFiles(
  23. getDefaultProguardFile("proguard-android-optimize.txt"),
  24. "proguard-rules.pro"
  25. )
  26. }
  27. }
  28. compileOptions {
  29. sourceCompatibility = JavaVersion.VERSION_1_8
  30. targetCompatibility = JavaVersion.VERSION_1_8
  31. }
  32. kotlinOptions {
  33. jvmTarget = "1.8"
  34. // 将数据库
  35. kapt {
  36. arguments {
  37. arg("room.schemaLocation", "$rootDir/schemas")
  38. }
  39. }
  40. }
  41. buildFeatures {
  42. compose = true
  43. }
  44. composeOptions {
  45. kotlinCompilerExtensionVersion = Sdk.compose
  46. }
  47. packagingOptions {
  48. resources {
  49. excludes += "/META-INF/{AL2.0,LGPL2.1}"
  50. }
  51. }
  52. }
  53. dependencies {
  54. // androidx
  55. implementation(Deps.Androidx.Core)
  56. implementation(Deps.Androidx.Appcompat)
  57. // google
  58. implementation(Deps.Google.Material)
  59. implementation(Deps.Google.Gson)
  60. implementation(Deps.Google.Accompanist.Insets)
  61. implementation(Deps.Google.Accompanist.InsetsUI)
  62. implementation(Deps.Google.Accompanist.FlowLayout)
  63. implementation(Deps.Google.Accompanist.SystemUiController)
  64. implementation(Deps.Google.Accompanist.SwipeRefresh)
  65. // lifecycle
  66. implementation(Deps.Lifecycle.Runtime)
  67. implementation(Deps.Lifecycle.Livedata)
  68. implementation(Deps.Lifecycle.ViewModel)
  69. implementation(Deps.Lifecycle.Compose)
  70. // room
  71. kapt(Deps.Room.Compiler)
  72. implementation(Deps.Room.Ktx)
  73. implementation(Deps.Room.Runtime)
  74. // navigation
  75. implementation(Deps.Navigation.Runtime)
  76. implementation(Deps.Navigation.Compose)
  77. // kodein
  78. implementation(Deps.Kodein.Di)
  79. implementation(Deps.Kodein.Compose)
  80. implementation(Deps.Kodein.Androidx)
  81. implementation(Deps.Kodein.ViewModel)
  82. // kotlinx
  83. implementation(Deps.Kotlinx.Json)
  84. // square
  85. implementation(Deps.Square.Retrofit)
  86. implementation(Deps.Square.Converter.Gson)
  87. implementation(Deps.Square.Interceptor.Logging)
  88. // Compose
  89. implementation(Deps.Compose.Animation)
  90. implementation(Deps.Compose.Compiler)
  91. implementation(Deps.Compose.Foundation)
  92. implementation(Deps.Compose.Material.Material)
  93. implementation(Deps.Compose.Material.Extended)
  94. implementation(Deps.Compose.Runtime.Runtime)
  95. implementation(Deps.Compose.Runtime.LiveData)
  96. implementation(Deps.Compose.UI.UI)
  97. implementation(Deps.Compose.UI.Preview)
  98. implementation(Deps.Compose.UI.Tooling)
  99. implementation(Deps.Compose.Paging)
  100. implementation(Deps.Compose.ConstraintLayout)
  101. // .Compose
  102. implementation(Deps.Androidx.Compose)
  103. implementation(Deps.Lifecycle.Compose)
  104. implementation(Deps.Navigation.Compose)
  105. // Coil
  106. implementation(Deps.Coil.Compose)
  107. // test
  108. testImplementation(Deps.Test.Junit)
  109. testImplementation(Deps.Room.Test)
  110. androidTestImplementation(Deps.AndroidXTest.Espresso)
  111. androidTestImplementation(Deps.Compose.Test.Compose)
  112. androidTestImplementation(Deps.AndroidXTest.Ktx)
  113. androidTestImplementation(Deps.AndroidXTest.Ext)
  114. debugImplementation(Deps.Compose.Debug.Tooling)
  115. //glide
  116. implementation(Deps.Glide.Glide)
  117. implementation(Deps.Glide.Rxjava)
  118. implementation(Deps.Glide.Rxandroid)
  119. implementation(Deps.Glide.Components)
  120. // implementation(Deps.Glide.Compiler)
  121. // implementation(Deps.Glide.annotations)
  122. // implementation(Deps.Glide.Okhttp3)
  123. // implementation(Deps.Glide.Logging)
  124. //db
  125. implementation(Deps.Tools.DebugDB)
  126. implementation(Deps.Tools.hutool)
  127. // implementation(Deps.Tools.Autosize)
  128. //Imgsel
  129. implementation(Deps.Imgsel.Imgsel)
  130. }