Skip to content

Commit eef9c44

Browse files
committed
remove buildScript block, use plugins instead
1 parent af5401e commit eef9c44

File tree

3 files changed

+13
-18
lines changed

3 files changed

+13
-18
lines changed

build.gradle.kts

+2-13
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,8 @@
11
// Top-level build file where you can add configuration options common to all sub-projects/modules.
22

3-
buildscript {
4-
repositories {
5-
google()
6-
mavenCentral()
7-
}
8-
dependencies {
9-
classpath(libs.gradle)
10-
classpath(libs.kotlin.gradle.plugin)
11-
// NOTE: Do not place your application dependencies here; they belong
12-
// in the individual module build.gradle files
13-
}
14-
}
15-
163
plugins {
4+
alias(libs.plugins.android) apply false
5+
alias(libs.plugins.kotlin) apply false
176
alias(libs.plugins.detekt) apply false
187
alias(libs.plugins.hilt) apply false
198
alias(libs.plugins.ksp) apply false

gradle/libs.versions.toml

+3-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ composeBom = "2024.06.00"
66
coreKtx = "1.13.1"
77
coreTesting = "2.2.0"
88
espressoCore = "3.6.1"
9-
gradle = "8.1.4"
9+
androidGradlePlugin = "8.1.4"
1010
gson = "2.10.1"
1111
hiltAndroid = "2.51.1"
1212
hiltNavigationCompose = "1.2.0"
@@ -59,10 +59,6 @@ logging-interceptor = { module = "com.squareup.okhttp3:logging-interceptor", ver
5959
okhttp = { module = "com.squareup.okhttp3:okhttp", version.ref = "okhttp" }
6060
work-runtime-ktx = { module = "androidx.work:work-runtime-ktx", version.ref = "workRuntimeKtx" }
6161

62-
# Gradle
63-
gradle = { module = "com.android.tools.build:gradle", version.ref = "gradle" }
64-
kotlin-gradle-plugin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlinGradlePlugin" }
65-
6662
# Retrofit
6763
retrofit = { module = "com.squareup.retrofit2:retrofit", version.ref = "retrofit" }
6864
retrofit2-kotlin-coroutines-adapter = { module = "com.jakewharton.retrofit:retrofit2-kotlin-coroutines-adapter", version.ref = "retrofit2KotlinCoroutinesAdapter" }
@@ -112,6 +108,8 @@ junit = { module = "androidx.test.ext:junit", version.ref = "junit" }
112108
espresso-core = { module = "androidx.test.espresso:espresso-core", version.ref = "espressoCore" }
113109

114110
[plugins]
111+
android = { id = "com.android.application", version.ref = "androidGradlePlugin" }
112+
kotlin = { id = "org.jetbrains.kotlin.android", version.ref = "kotlinGradlePlugin" }
115113
detekt = { id = "io.gitlab.arturbosch.detekt", version.ref = "detekt" }
116114
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
117115
ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" }

settings.gradle

+8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
pluginManagement {
2+
repositories {
3+
google()
4+
mavenCentral()
5+
gradlePluginPortal()
6+
}
7+
}
8+
19
include ':presentation'
210
include ':domain'
311
include ':data'

0 commit comments

Comments
 (0)