Skip to content

Commit

Permalink
switch to KSP for the Daggger & Hilt compilers
Browse files Browse the repository at this point in the history
  • Loading branch information
frett committed Sep 15, 2023
1 parent c940428 commit 0096353
Show file tree
Hide file tree
Showing 13 changed files with 39 additions and 38 deletions.
4 changes: 2 additions & 2 deletions feature/bundledcontent/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.dynamic-feature-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android.namespace = "org.cru.godtools.feature.bundledcontent"
Expand All @@ -12,5 +12,5 @@ dependencies {

implementation(libs.dagger)

kapt(libs.dagger.compiler)
ksp(libs.dagger.compiler)
}
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ androidx-compose-compiler = "1.5.3"
androidx-compose-material = "1.5.1"
androidx-compose-ui = "1.5.1"
androidx-core = "1.12.0"
androidx-hilt = "1.0.0"
androidx-hilt = "1.1.0-alpha01"
androidx-lifecycle = "2.6.2"
androidx-room = "2.5.2"
androidx-viewpager2 = "1.0.0"
Expand Down
6 changes: 3 additions & 3 deletions library/account/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android.namespace = "org.cru.godtools.account"
Expand All @@ -25,8 +25,8 @@ dependencies {
implementation(libs.play.auth)
// endregion Google

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(kotlin("test"))
testImplementation(libs.kotlin.coroutines.test)
Expand Down
6 changes: 3 additions & 3 deletions library/analytics/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -42,8 +42,8 @@ dependencies {
implementation(libs.play.tagmanager)
implementation(libs.weakdelegate)

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(kotlin("test"))
testImplementation(libs.kotlin.coroutines.test)
Expand Down
7 changes: 4 additions & 3 deletions library/base/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android.namespace = "org.cru.godtools.base"
Expand All @@ -23,8 +23,9 @@ dependencies {
implementation(libs.dagger)
implementation(libs.hilt)
implementation(libs.kotlin.coroutines)
kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)

ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(libs.kotlin.coroutines.test)
testImplementation(libs.turbine)
Expand Down
6 changes: 2 additions & 4 deletions library/db/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

Expand Down Expand Up @@ -37,10 +36,9 @@ dependencies {
implementation(libs.dagger)
implementation(libs.hilt)

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)

ksp(libs.androidx.room.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(kotlin("test"))
testImplementation(libs.androidx.room.testing)
Expand Down
9 changes: 5 additions & 4 deletions library/download-manager/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -39,13 +40,13 @@ dependencies {
implementation(libs.hilt)
implementation(libs.kotlin.coroutines)

kapt(libs.androidx.hilt.compiler)
kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.androidx.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(libs.androidx.arch.core.testing)
testImplementation(libs.hilt.testing)
testImplementation(libs.kotlin.coroutines.test)
testImplementation(libs.turbine)
kaptTest(libs.hilt.compiler)
kspTest(libs.hilt.compiler)
}
4 changes: 2 additions & 2 deletions library/initial-content/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import org.cru.godtools.gradle.bundledcontent.configureBundledContent

plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -46,5 +46,5 @@ dependencies {

testImplementation(libs.kotlin.coroutines.test)

kapt(libs.hilt.compiler)
ksp(libs.hilt.compiler)
}
8 changes: 4 additions & 4 deletions library/sync/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android.namespace = "org.cru.godtools.sync"
Expand All @@ -27,7 +27,7 @@ dependencies {

testImplementation(libs.kotlin.coroutines.test)

kapt(libs.androidx.hilt.compiler)
kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.androidx.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)
}
6 changes: 3 additions & 3 deletions library/user-data/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.ksp)
}

android.namespace = "org.cru.godtools.user"
Expand All @@ -17,8 +17,8 @@ dependencies {

implementation(libs.dagger)

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(kotlin("test"))
testImplementation(libs.kotlin.coroutines.test)
Expand Down
5 changes: 3 additions & 2 deletions ui/base/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.hilt)
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -50,8 +51,8 @@ dependencies {
implementation(libs.hilt)
implementation(libs.youtubePlayer)

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)

testImplementation(project(":ui:tract-renderer"))
}
8 changes: 4 additions & 4 deletions ui/shortcuts/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.hilt)
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -36,7 +36,7 @@ dependencies {
testImplementation(libs.gtoSupport.testing.timber)
testImplementation(libs.kotlin.coroutines.test)

kapt(libs.androidx.hilt.compiler)
kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.androidx.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)
}
6 changes: 3 additions & 3 deletions ui/tutorial-renderer/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
plugins {
id("godtools.library-conventions")
kotlin("kapt")
alias(libs.plugins.hilt)
alias(libs.plugins.ksp)
}

android {
Expand Down Expand Up @@ -46,6 +46,6 @@ dependencies {
implementation(libs.splitties.intents)
implementation(libs.youtubePlayer)

kapt(libs.dagger.compiler)
kapt(libs.hilt.compiler)
ksp(libs.dagger.compiler)
ksp(libs.hilt.compiler)
}

0 comments on commit 0096353

Please sign in to comment.