Skip to content

Commit 3555ee5

Browse files
committed
Swap from kapt to KSP
1 parent 78eb7b9 commit 3555ee5

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

build.gradle.kts

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
import org.gradle.api.tasks.testing.logging.TestExceptionFormat.FULL
22

3-
apply(plugin = "kotlin")
4-
apply(plugin = "kotlin-kapt")
5-
63
java {
74
sourceCompatibility = JavaVersion.VERSION_17
85
targetCompatibility = JavaVersion.VERSION_17
@@ -14,7 +11,7 @@ kotlin {
1411

1512
plugins {
1613
kotlin("jvm") version "1.9.22"
17-
kotlin("kapt") version "1.9.22"
14+
id("com.google.devtools.ksp") version "1.9.22-1.0.16"
1815
application
1916
jacoco
2017
}
@@ -41,10 +38,10 @@ dependencies {
4138
// used for generating skeletons
4239
implementation("com.squareup:kotlinpoet:1.18.1")
4340

44-
// dependency injection library and annotation procressing
41+
// dependency injection library and annotation processing
4542
implementation("com.google.dagger:dagger:2.57.2")
46-
kapt("com.google.dagger:dagger-compiler:2.57.2")
47-
kaptTest("com.google.dagger:dagger-compiler:2.57.2")
43+
ksp("com.google.dagger:dagger-compiler:2.57.2")
44+
kspTest("com.google.dagger:dagger-compiler:2.57.2")
4845

4946
// test libraries
5047
testImplementation(kotlin("test"))
@@ -80,7 +77,7 @@ jacoco {
8077
sourceSets {
8178
test {
8279
java {
83-
setSrcDirs(listOf("build/generated/source/kapt/test"))
80+
setSrcDirs(listOf("build/generated/ksp/test/kotlin"))
8481
}
8582
}
8683
}

0 commit comments

Comments
 (0)