build.gradle 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. apply plugin: 'com.android.application'
  2. apply plugin: 'kotlin-android'
  3. apply plugin: 'com.google.gms.google-services'
  4. android {
  5. compileSdkVersion 34
  6. useLibrary 'org.apache.http.legacy'
  7. sourceSets.main
  8. {
  9. jniLibs.srcDirs = ['libs']
  10. }
  11. dexOptions {
  12. javaMaxHeapSize "4g"
  13. }
  14. defaultConfig {
  15. applicationId "com.sikey.veryfit"
  16. // vectorDrawables.useSupportLibrary = true
  17. minSdkVersion 26
  18. targetSdkVersion 35
  19. versionCode 23
  20. versionName "0.6.25"
  21. multiDexEnabled true
  22. //manifestPlaceholders=[UMENG_CHANNEL_VALUE:name]
  23. }
  24. packagingOptions {
  25. resources {
  26. excludes += ['META-INF/DEPENDENCIES', 'META-INF/NOTICE', 'META-INF/LICENSE', 'META-INF/LICENSE.txt', 'META-INF/NOTICE.txt']
  27. }
  28. }
  29. signingConfigs {
  30. debug {
  31. storeFile file("../release_keystore_sikey.jks")
  32. storePassword "sikey2024"
  33. keyAlias "SikeyRelease"
  34. keyPassword "sikey2024"
  35. }
  36. release {
  37. storeFile file("../release_keystore_sikey.jks")
  38. storePassword "sikey2024"
  39. keyAlias "SikeyRelease"
  40. keyPassword "sikey2024"
  41. }
  42. }
  43. buildTypes {
  44. debug {
  45. //show log
  46. buildConfigField "boolean", "LOG_DEBUG", "true"
  47. versionNameSuffix ""
  48. minifyEnabled false
  49. zipAlignEnabled false
  50. shrinkResources false
  51. signingConfig signingConfigs.debug
  52. }
  53. release {
  54. signingConfig signingConfigs.release
  55. //do not show log
  56. buildConfigField "boolean", "LOG_DEBUG", "false"
  57. //zipalign optimize
  58. zipAlignEnabled true
  59. //remove unused resource files
  60. shrinkResources true
  61. //proguardFiles 'proguard-android.txt','proguard-rules.pro'
  62. minifyEnabled true
  63. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  64. }
  65. }
  66. /*
  67. productFlavors{
  68. GooglePlay {}
  69. xiaomi {}
  70. umeng {}
  71. _360 {}
  72. baidu {}
  73. _91 {}
  74. wandoujia {}
  75. yingyongbao{}
  76. }
  77. productFlavors.all{
  78. flavor->flavor.manifestPlaceholders=[UMENG_CHANNEL_VALUE: name]
  79. }
  80. applicationVariants.all{ variant->
  81. variant.outputs.each{ output->
  82. def outputFile=output.outputFile
  83. if(outputFile!=null && outputFile.name.endsWith('.apk')){
  84. def fileName=outputFile.name.replace(".apk","-${defaultConfig.versionName}.apk")
  85. output.outputFile=new File(outputFile.parent,fileName)
  86. }
  87. }
  88. }
  89. */
  90. repositories {
  91. flatDir {
  92. // this way we can find the .aar file in libs folder
  93. dirs 'libs'
  94. }
  95. }
  96. compileOptions {
  97. targetCompatibility 17
  98. sourceCompatibility 17
  99. }
  100. kotlinOptions {
  101. jvmTarget = '17'
  102. }
  103. lint {
  104. abortOnError false
  105. disable 'MissingTranslation'
  106. }
  107. namespace 'com.sikey.veryfit'
  108. buildFeatures {
  109. buildConfig true
  110. }
  111. }
  112. dependencies {
  113. implementation 'androidx.multidex:multidex:2.0.1'
  114. implementation fileTree(include: ['*.jar'], dir: 'libs')
  115. implementation(name: 'crop_image', ext: 'aar')
  116. //compile project(':social_sdk_library_project')
  117. // implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
  118. implementation 'com.google.android.material:material:1.9.0'
  119. //kotlin coroutines
  120. implementation(platform('org.jetbrains.kotlin:kotlin-bom:1.8.0'))
  121. implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.7.1"
  122. implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.1"
  123. // androidX
  124. implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.6.2'
  125. implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.6.2'
  126. implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.2'
  127. implementation 'androidx.appcompat:appcompat:1.6.1'
  128. implementation 'androidx.activity:activity-ktx:1.7.0'
  129. implementation 'androidx.fragment:fragment-ktx:1.5.6'
  130. implementation 'androidx.legacy:legacy-support-v4:1.0.0'
  131. implementation 'androidx.recyclerview:recyclerview:1.3.0'
  132. implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
  133. implementation 'androidx.cardview:cardview:1.0.0'
  134. implementation 'androidx.transition:transition:1.4.1'
  135. implementation 'androidx.exifinterface:exifinterface:1.3.6'
  136. implementation 'com.airbnb.android:lottie:3.0.0'
  137. implementation 'com.ashokvarma.android:bottom-navigation-bar:1.3.1'
  138. implementation 'com.lcodecorex:tkrefreshlayout:1.0.5'
  139. //zxing核心依赖
  140. implementation 'com.google.zxing:core:3.5.0'
  141. implementation 'com.journeyapps:zxing-android-embedded:4.3.0'
  142. implementation 'com.koushikdutta.async:androidasync:2.2.1'
  143. // GMS
  144. implementation 'com.google.android.gms:play-services-maps:18.1.0'
  145. implementation 'com.google.android.libraries.places:places:3.0.0'
  146. implementation 'com.google.android.gms:play-services-location:21.0.1'
  147. implementation 'com.google.android.gms:play-services-auth:20.4.1'
  148. implementation 'com.google.android.gms:play-services-basement:18.2.0'
  149. implementation 'com.github.pengrad:mapscaleview:1.2.1'
  150. // implementation 'com.google.firebase:firebase-messaging:23.4.0'
  151. implementation 'com.google.firebase:firebase-messaging-ktx:23.4.0'
  152. implementation 'com.google.firebase:firebase-core:21.1.1'
  153. implementation(platform("com.google.firebase:firebase-bom:32.7.1"))
  154. //rxpremissions
  155. implementation 'io.reactivex.rxjava2:rxjava:2.2.21'
  156. implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
  157. implementation 'com.tbruyelle.rxpermissions2:rxpermissions:0.9.4@aar'
  158. //retrofit
  159. implementation 'com.squareup.retrofit2:retrofit:2.9.0'
  160. implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
  161. implementation 'com.squareup.retrofit2:adapter-rxjava2:2.9.0'
  162. implementation 'com.squareup.retrofit2:retrofit-converters:2.5.0'
  163. implementation 'com.squareup.okhttp3:logging-interceptor:5.0.0-alpha.10'
  164. implementation 'io.reactivex.rxjava2:rxjava:2.2.21'
  165. implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
  166. //gson
  167. implementation 'com.google.code.gson:gson:2.10'
  168. implementation 'org.greenrobot:eventbus:3.1.0-RC'
  169. implementation 'com.github.yalantis:ucrop:2.2.8'
  170. // Baidu Map
  171. implementation (name: 'BaiduLBS_Android_V7.6.5', ext: 'aar')
  172. implementation 'org.locationtech.jts:jts-core:1.19.0'
  173. implementation 'org.locationtech.jts.io:jts-io-common:1.19.0'
  174. }