build: 版本兼容升级

1. agp -> v8.1.0
2. gradle -> v8.0
3. 添加 gradle version catalogs 管理依赖,替换 buildSrc 方式,目前只将插件部分重构,其余依赖后续版本中重构
This commit is contained in:
Quyunshuo
2023-08-20 20:23:09 +08:00
parent 2fd0c18b29
commit 337f7fa15e
18 changed files with 130 additions and 115 deletions

20
gradle/libs.versions.toml Normal file
View File

@ -0,0 +1,20 @@
[versions]
# plugin
agp = "8.1.0"
kotlin-android = "1.8.0"
hilt = "2.44"
#lib
[libraries]
[plugins]
application = { id = "com.android.application", version.ref = "agp" }
library = { id = "com.android.library", version.ref = "agp" }
kotlin = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin-android" }
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
[bundles]

View File

@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip