Skip to content
This repository has been archived by the owner on Feb 2, 2025. It is now read-only.

Commit

Permalink
Cleaning up build warnings
Browse files Browse the repository at this point in the history
Example of warning:

>  > Configure project :kotest-assertions-arrow-fx-coroutines
>  w: A compileOnly dependency is used in targets: Kotlin/JS.
>  Dependencies:
>      - io.arrow-kt:arrow-fx-coroutines:2.0.0 (source sets: jsMain)
>
>  Using compileOnly dependencies in these targets is not currently supported, because compileOnly dependencies must be present during the compilation of projects that depend on this project.
>
>  To ensure consistent compilation behaviour, compileOnly dependencies should be exposed as api dependencies.
>
>  Example:
>
>      kotlin {
>          sourceSets {
>              nativeMain {
>                  dependencies {
>                      compileOnly("org.example:lib:1.2.3")
>                      // additionally add the compileOnly dependency as an api dependency:
>                      api("org.example:lib:1.2.3")
>                  }
>              }
>          }
>      }
>
>  This warning can be suppressed in gradle.properties:
>
>      kotlin.suppressGradlePluginWarnings=IncorrectCompileOnlyDependencyWarning
  • Loading branch information
Kantis committed Dec 7, 2024
1 parent 8e7e5d7 commit a1bfb4a
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 0 deletions.
6 changes: 6 additions & 0 deletions kotest-assertions-arrow-fx-coroutines/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ kotlin {
}
}

jsMain {
dependencies {
api(libs.arrow.fx.coroutines)
}
}

nativeMain {
dependencies {
implementation(libs.arrow.fx.coroutines)
Expand Down
6 changes: 6 additions & 0 deletions kotest-assertions-arrow/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ kotlin {
}
}

jsMain {
dependencies {
api(libs.arrow.core)
}
}

nativeMain {
dependencies {
implementation(libs.arrow.core)
Expand Down
6 changes: 6 additions & 0 deletions kotest-property-arrow-optics/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ kotlin {
}
}

jsMain {
dependencies {
api(libs.arrow.optics)
}
}

nativeMain {
dependencies {
implementation(libs.arrow.optics)
Expand Down
6 changes: 6 additions & 0 deletions kotest-property-arrow/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ kotlin {
}
}

jsMain {
dependencies {
api(libs.arrow.core)
}
}

nativeMain {
dependencies {
implementation(libs.arrow.core)
Expand Down

0 comments on commit a1bfb4a

Please sign in to comment.