build.gradle 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. // Top-level build file where you can add configuration options common to all sub-projects/modules.
  2. apply from: "config.gradle"
  3. buildscript {
  4. ext.kotlin_version = "1.6.10"
  5. repositories {
  6. // maven { url 'http://127.0.0.1:1022/repository/maven-public/' }
  7. maven {
  8. allowInsecureProtocol true
  9. url 'http://xuqinmin.com.cn:8081/repository/android-group/'
  10. }
  11. }
  12. dependencies {
  13. classpath 'com.android.tools.build:gradle:7.2.0'
  14. classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.0"
  15. // NOTE: Do not place your application dependencies here; they belong
  16. // in the individual module build.gradle files
  17. }
  18. }
  19. allprojects {
  20. repositories {
  21. // google()
  22. // jcenter()
  23. // maven { url 'http://developer.huawei.com/repo/' }
  24. // maven { url 'http://127.0.0.1:1022/repository/maven-public/' }
  25. maven {
  26. allowInsecureProtocol true
  27. url 'http://xuqinmin.com.cn:8081/repository/android-group/'
  28. }
  29. maven { url 'https://jitpack.io' }
  30. }
  31. }
  32. //全局配置,所有module都可以用到
  33. subprojects {
  34. afterEvaluate {
  35. android {
  36. buildFeatures.dataBinding = true
  37. compileOptions {
  38. sourceCompatibility JavaVersion.VERSION_11
  39. targetCompatibility JavaVersion.VERSION_11
  40. }
  41. kotlinOptions {
  42. jvmTarget = "11"
  43. }
  44. }
  45. }
  46. }
  47. task clean(type: Delete) {
  48. delete rootProject.buildDir
  49. }