学习机 新
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

207 lines
6.2KB

  1. apply plugin: 'com.android.application'
  2. def useLinkKitAarDep = true
  3. android {
  4. compileSdkVersion 30
  5. defaultConfig {
  6. applicationId "com.telpo.alink"
  7. minSdkVersion 21
  8. targetSdkVersion 30
  9. versionCode 2
  10. versionName "1.2.37"
  11. multiDexEnabled true
  12. testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
  13. //https://developer.android.com/studio/build/multidex#multidexkeepfile-property
  14. multiDexKeepFile file('multidex-config.txt')
  15. archivesBaseName = "TelpoAlink_${versionName}"
  16. ndk {
  17. abiFilters = []
  18. abiFilters.addAll(rootProject.ext.abiFilters)
  19. }
  20. /* 集成组件 TUIOfflinePush 离线推送功能需要配置下厂商 vivo 的应用信息,不需要离线推送功能删除即可。
  21. *
  22. * "VIVO_APPKEY" : 厂商推送平台注册应用的 AppKey
  23. * "VIVO_APPID" : 厂商推送平台注册应用的 AppID
  24. */
  25. manifestPlaceholders = [
  26. "VIVO_APPKEY" : " ",
  27. "VIVO_APPID" : " ",
  28. "HONOR_APPID" : " "
  29. ]
  30. }
  31. signingConfigs {
  32. /*
  33. debug {
  34. keyAlias 'IoTTestKey'
  35. keyPassword 'test1234'
  36. storeFile file('config/test.release.keystore.jks')
  37. storePassword 'admin1234'
  38. }
  39. release {
  40. keyAlias 'IoTTestKey'
  41. keyPassword 'test1234'
  42. storeFile file('config/test.release.keystore.jks')
  43. storePassword 'admin1234'
  44. }*/
  45. //系统应用调试
  46. debug {
  47. keyAlias 'platform'
  48. keyPassword '123456'
  49. storeFile file('config/platform.keystore')
  50. storePassword '123456'
  51. }
  52. release {
  53. keyAlias 'platform'
  54. keyPassword '123456'
  55. storeFile file('config/platform.keystore')
  56. storePassword '123456'
  57. }
  58. }
  59. buildTypes {
  60. /*debug {
  61. debuggable true
  62. signingConfig signingConfigs.debug
  63. minifyEnabled false
  64. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  65. }*/
  66. release {
  67. minifyEnabled false
  68. signingConfig signingConfigs.release
  69. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  70. }
  71. }
  72. lintOptions{
  73. abortOnError false
  74. }
  75. compileOptions {
  76. sourceCompatibility JavaVersion.VERSION_1_8
  77. targetCompatibility JavaVersion.VERSION_1_8
  78. }
  79. sourceSets {
  80. main {
  81. jniLibs.srcDirs = ['libs']
  82. }
  83. }
  84. repositories {
  85. flatDir {
  86. dirs 'libs' //this way we can find the .aar file in libs folder
  87. }
  88. }
  89. // 主题资源文件夹
  90. sourceSets {
  91. main {
  92. res.srcDirs += "src/main/res-light"
  93. res.srcDirs += "src/main/res-lively"
  94. res.srcDirs += "src/main/res-serious"
  95. res.srcDirs += "src/main/self-res"
  96. }
  97. }
  98. }
  99. repositories {
  100. flatDir {
  101. dirs 'libs' //this way we can find the .aar file in libs folder
  102. }
  103. maven {
  104. url "https://maven.aliyun.com/nexus/content/repositories/releases/"
  105. }
  106. }
  107. configurations.all {
  108. resolutionStrategy {
  109. cacheChangingModulesFor(0, 'SECONDS')
  110. }
  111. resolutionStrategy.force 'com.android.support:support-v4:28.0.0'
  112. resolutionStrategy.force 'com.android.support:support-v7:28.0.0'
  113. all*.exclude group: 'com.aliyun.iot.aep.sdk.external', module:'securityguard'
  114. }
  115. dependencies {
  116. implementation fileTree(dir: 'libs', include: ['*.jar'])
  117. implementation fileTree(dir: 'libs', include: ['*.aar'])
  118. if (useLinkKitAarDep) {
  119. implementation ('com.aliyun.alink.linksdk:iot-linkkit:1.7.2') {
  120. transitive = true
  121. changing = true
  122. }
  123. } else {
  124. compile project(':IoTLinkKit')
  125. }
  126. api project(':tuicommunity')
  127. api project(':tuiconversation')
  128. api project(':tuicontact')
  129. api project(':tuichat')
  130. api project(':tuisearch')
  131. api project(':tuigroup')
  132. api project(':tuicallkit')
  133. api project(':tuiofflinepush')
  134. implementation 'com.aliyun.alink.linksdk:iot-device-manager:1.7.5.4'
  135. implementation files('libs/pinyin4j-2.5.0.jar')
  136. implementation files('libs/gesture-imageview.jar')
  137. implementation files('libs/reactor-core-3.3.17.RELEASE.jar')
  138. compile('com.aliyun.alink.linksdk:public-channel-core:0.7.7.1')
  139. implementation 'com.squareup.okhttp3:okhttp:3.12.8'
  140. implementation 'com.google.code.gson:gson:2.9.1'
  141. implementation 'androidx.cardview:cardview:1.0.0'
  142. // bugly sdk
  143. implementation 'com.tencent.bugly:crashreport:latest.release'
  144. implementation 'com.tencent.bugly:nativecrashreport:latest.release'
  145. implementation 'androidx.asynclayoutinflater:asynclayoutinflater:1.0.0'
  146. implementation 'androidx.vectordrawable:vectordrawable-animated:1.1.0'
  147. implementation 'androidx.multidex:multidex:2.0.1'
  148. implementation 'androidx.recyclerview:recyclerview:1.2.1'
  149. implementation 'androidx.appcompat:appcompat:1.3.1'
  150. implementation 'com.google.android.material:material:1.4.0'
  151. implementation 'com.github.bumptech.glide:glide:4.12.0'
  152. implementation 'org.greenrobot:greendao:3.2.0'
  153. implementation 'io.reactivex.rxjava2:rxjava:2.2.17'
  154. implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
  155. implementation 'io.github.jeremyliao:live-event-bus-x:1.8.0'
  156. implementation 'com.blankj:utilcodex:1.31.1'
  157. implementation 'com.squareup.retrofit2:retrofit:2.9.0'
  158. implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
  159. implementation "com.github.CymChad:BaseRecyclerViewAdapterHelper:3.0.4"
  160. implementation 'com.fasterxml.jackson.core:jackson-databind:2.12.3'
  161. implementation 'org.greenrobot:eventbus:3.2.0'
  162. def projects = this.rootProject.getAllprojects().stream().map { project -> project.name }.collect()
  163. if (projects.contains("tuigroupnote")) {
  164. api project(':tuigroupnote')
  165. } else {
  166. api "com.tencent.imsdk.tuiplugin:tuigroupnote:7.1.3925"
  167. }
  168. if (projects.contains("tuipoll")) {
  169. api project(':tuipoll')
  170. } else {
  171. api "com.tencent.imsdk.tuiplugin:tuipoll:7.1.3925"
  172. }
  173. }