aboutsummaryrefslogtreecommitdiff
path: root/buildSrc/src
diff options
context:
space:
mode:
Diffstat (limited to 'buildSrc/src')
-rw-r--r--buildSrc/src/main/kotlin/SpotlessConfiguration.kt16
1 files changed, 10 insertions, 6 deletions
diff --git a/buildSrc/src/main/kotlin/SpotlessConfiguration.kt b/buildSrc/src/main/kotlin/SpotlessConfiguration.kt
index 3c183c5f..71cfc558 100644
--- a/buildSrc/src/main/kotlin/SpotlessConfiguration.kt
+++ b/buildSrc/src/main/kotlin/SpotlessConfiguration.kt
@@ -1,3 +1,7 @@
+/*
+ * Copyright © 2014-2019 The Android Password Store Authors. All Rights Reserved.
+ * SPDX-License-Identifier: GPL-2.0
+ */
import com.diffplug.gradle.spotless.SpotlessExtension
import com.diffplug.gradle.spotless.SpotlessPlugin
import org.gradle.api.Project
@@ -17,8 +21,8 @@ fun Project.configureSpotless() {
java {
target("**/src/main/**/*.java")
trimTrailingWhitespace()
- // @Suppress("INACCESSIBLE_TYPE")
- // licenseHeader(kotlinLicenseHeader)
+ @Suppress("INACCESSIBLE_TYPE")
+ licenseHeader(kotlinLicenseHeader)
removeUnusedImports()
googleJavaFormat().aosp()
endWithNewline()
@@ -27,8 +31,8 @@ fun Project.configureSpotless() {
kotlinGradle {
target("*.gradle.kts", "gradle/*.gradle.kts", "buildSrc/*.gradle.kts")
ktlint("0.31.0").userData(mapOf("indent_size" to "4", "continuation_indent_size" to "4"))
- // @Suppress("INACCESSIBLE_TYPE")
- // licenseHeader(kotlinLicenseHeader, "import|tasks|apply|plugins|include")
+ @Suppress("INACCESSIBLE_TYPE")
+ licenseHeader(kotlinLicenseHeader, "import|tasks|apply|plugins|include|buildscript")
trimTrailingWhitespace()
indentWithSpaces()
endWithNewline()
@@ -37,8 +41,8 @@ fun Project.configureSpotless() {
kotlin {
target("**/src/main/**/*.kt", "buildSrc/**/*.kt")
ktlint("0.31.0").userData(mapOf("indent_size" to "4", "continuation_indent_size" to "4"))
- // @Suppress("INACCESSIBLE_TYPE")
- // licenseHeader(kotlinLicenseHeader)
+ @Suppress("INACCESSIBLE_TYPE")
+ licenseHeader(kotlinLicenseHeader, "import|package|class|object|@file")
trimTrailingWhitespace()
indentWithSpaces()
endWithNewline()