From 1581d2e00ce62d57f783d8a53a023d7d172691cc Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Sat, 22 Jul 2023 15:44:52 +0530 Subject: fix(build): only enable `-Werror` in CI --- .../src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'build-logic/src/main/kotlin/app') diff --git a/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt b/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt index 5a0b14a8..68195033 100644 --- a/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt +++ b/build-logic/src/main/kotlin/app/passwordstore/gradle/KotlinCommonPlugin.kt @@ -24,7 +24,7 @@ class KotlinCommonPlugin : Plugin { project.tasks.run { withType().configureEach task@{ compilerOptions { - allWarningsAsErrors.set(true) + allWarningsAsErrors.set(project.providers.environmentVariable("CI").isPresent) languageVersion.set(KotlinVersion.KOTLIN_1_9) freeCompilerArgs.addAll(ADDITIONAL_COMPILER_ARGS) if (!this@task.name.contains("test", ignoreCase = true) && !isAppModule) { -- cgit v1.2.3