build.gradle 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. plugins {
  2. id 'com.android.application'
  3. id 'org.jetbrains.kotlin.android'
  4. id 'kotlin-kapt'
  5. id 'kotlinx-serialization'
  6. }
  7. ext{
  8. versionCode=230407200
  9. brandCode="000A"
  10. brandVersionCode=versionCode
  11. model="1037"
  12. }
  13. android {
  14. compileSdk 31
  15. defaultConfig {
  16. applicationId "com.develop.foodcooking"
  17. minSdk 21
  18. targetSdk 30
  19. versionCode project.ext.versionCode
  20. versionName "${project.ext.model}.${project.ext.brandCode}.${project.ext.brandVersionCode}.${project.ext.versionCode}"
  21. archivesBaseName = "cofar-cooking_${versionName}"
  22. javaCompileOptions {
  23. annotationProcessorOptions {
  24. arguments = ["room.schemaLocation": "$projectDir/schemas".toString()]
  25. }
  26. }
  27. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  28. kapt {
  29. arguments {
  30. arg("AROUTER_MODULE_NAME", project.getName())
  31. arg("room.schemaLocation", "$projectDir/schemas".toString())
  32. }
  33. }
  34. multiDexEnabled true
  35. }
  36. signingConfigs {
  37. debug {
  38. storeFile file('..\\signature\\rk.jks')
  39. storePassword '123456'
  40. keyAlias 'rk'
  41. keyPassword '123456'
  42. }
  43. foodCooking {
  44. storeFile file("..\\signature\\rk.jks")
  45. storePassword '123456'
  46. keyAlias 'rk'
  47. keyPassword '123456'
  48. }
  49. release {
  50. storeFile file('..\\signature\\rk.jks')
  51. storePassword '123456'
  52. keyAlias 'rk'
  53. keyPassword '123456'
  54. }
  55. }
  56. buildTypes {
  57. release {
  58. minifyEnabled false
  59. signingConfig signingConfigs.release
  60. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
  61. }
  62. }
  63. compileOptions {
  64. sourceCompatibility JavaVersion.VERSION_1_8
  65. targetCompatibility JavaVersion.VERSION_1_8
  66. }
  67. kotlinOptions {
  68. jvmTarget = '1.8'
  69. }
  70. viewBinding {
  71. enabled = true
  72. }
  73. }
  74. dependencies {
  75. implementation project(path: ':libBase') //基础工具模块,不涉及业务逻辑
  76. implementation project(path: ':BusinessCommon')//业务相关的基础类
  77. implementation project(path: ':BusinessMain') //烹饪主模块
  78. implementation project(path: ':BusinessAuth')//登录-注册-个人信息模块
  79. implementation project(path: ':BusinessSetting') //设置模块
  80. implementation project(path: ':BusinessStep') //烹饪步骤模块
  81. kapt 'com.alibaba:arouter-compiler:1.5.2'
  82. }