From 96a9211f9eeb2bb12fb5cc745f7955dfda95014b Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Tue, 9 Nov 2021 21:33:59 +0530 Subject: build-logic: migrate Spotless to a convention plugin --- buildSrc/src/main/java/Spotless.kt | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100644 buildSrc/src/main/java/Spotless.kt (limited to 'buildSrc/src') diff --git a/buildSrc/src/main/java/Spotless.kt b/buildSrc/src/main/java/Spotless.kt deleted file mode 100644 index bab6f58d..00000000 --- a/buildSrc/src/main/java/Spotless.kt +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved. - * SPDX-License-Identifier: GPL-3.0-only - */ - -import com.diffplug.gradle.spotless.SpotlessExtension -import org.gradle.api.Project -import org.gradle.kotlin.dsl.apply -import org.gradle.kotlin.dsl.configure - -fun Project.configureSpotless() { - apply(plugin = "com.diffplug.spotless") - configure { - kotlin { - ktfmt().googleStyle() - target("**/*.kt") - targetExclude("**/build/") - } - kotlinGradle { - ktfmt().googleStyle() - target("**/*.kts") - } - format("xml") { - target("**/*.xml") - targetExclude("**/build/", ".idea/") - trimTrailingWhitespace() - indentWithSpaces() - endWithNewline() - } - } -} -- cgit v1.2.3