diff --git a/build-plugin/README.md b/build-logic/README.md similarity index 94% rename from build-plugin/README.md rename to build-logic/README.md index 34cae4f..3cdfd2c 100644 --- a/build-plugin/README.md +++ b/build-logic/README.md @@ -1,13 +1,13 @@ -# Build plugins +# Build logic -The `build-plugin` project provides a set of Gradle plugins that act as the single source of truth for +The `build-logic` project provides a set of Gradle plugins that act as the single source of truth for project-wide build configuration. This avoids duplicated build script setups and centralizes common build logic. ## Background We use an included build to host our build logic as real Gradle plugins (written in Kotlin), not as legacy -`*.gradle.kts` convention scripts. The included build is located at `build-plugin/plugin` and registers plugins -via the Gradle `gradlePlugin` block in `build-plugin/plugin/build.gradle.kts`. +`*.gradle.kts` convention scripts. The included build is located at `build-logic/plugin` and registers plugins +via the Gradle `gradlePlugin` block in `build-logic/plugin/build.gradle.kts`. You apply these plugins in modules using their fully-qualified plugin IDs. Each plugin focuses on a single responsibility; one-off configuration should stay in the module’s own `build.gradle.kts`. @@ -184,17 +184,17 @@ Alternatively, you may provide equivalent Gradle properties via other supported These plugins are provided by an included build. The root `settings.gradle.kts` contains: ``` -includeBuild("build-plugin") +includeBuild("build-logic") ``` ## Creating a new build plugin -1. Create a Kotlin plugin class under `build-plugin/plugin/src/main/kotlin/...`, implementing `Plugin`. -2. Register it in `build-plugin/plugin/build.gradle.kts` inside the `gradlePlugin { plugins { ... } }` block with a +1. Create a Kotlin plugin class under `build-logic/plugin/src/main/kotlin/...`, implementing `Plugin`. +2. Register it in `build-logic/plugin/build.gradle.kts` inside the `gradlePlugin { plugins { ... } }` block with a unique ID and the `implementationClass` pointing to your class. 3. Dependencies: - Add versions and aliases to the version catalog `gradle/libs.versions.toml` (if not present yet). - - Add the dependency to `build-plugin/plugin/build.gradle.kts`. + - Add the dependency to `build-logic/plugin/build.gradle.kts`. - Plugin dependency: `implementation(plugin(libs.plugins.YOUR_PLUGIN))` - Library dependency: `implementation(libs.YOUR_LIBRARY)` diff --git a/build-plugin/gradle.properties b/build-logic/gradle.properties similarity index 100% rename from build-plugin/gradle.properties rename to build-logic/gradle.properties diff --git a/build-plugin/plugin/build.gradle.kts b/build-logic/plugin/build.gradle.kts similarity index 94% rename from build-plugin/plugin/build.gradle.kts rename to build-logic/plugin/build.gradle.kts index 7e6417c..1eea146 100644 --- a/build-plugin/plugin/build.gradle.kts +++ b/build-logic/plugin/build.gradle.kts @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ plugins { `kotlin-dsl` } diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt similarity index 64% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt index 31c5374..6216e72 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Compose.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin import org.gradle.api.plugins.ExtensionAware diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt similarity index 54% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt index 914119e..c932a2a 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/Libs.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin import org.gradle.accessors.dm.LibrariesForLibs diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt similarity index 86% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt index 2c1cbae..8f7c3c2 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/ProjectConfig.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin import org.gradle.api.JavaVersion diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt index cf18377..16c05e2 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/app/kmp/compose/AppKmpComposePlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.app.kmp.compose import com.android.build.api.dsl.ApplicationExtension diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt similarity index 76% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt index 658e298..7f77230 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/bom/BomPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.bom import org.gradle.api.Plugin diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt index ab7f437..5dd64b1 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt index 6bba062..80ace78 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import kotlin.time.Clock diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt similarity index 96% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt index f4f4cd3..0184958 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import net.thunderbird.gradle.plugin.changelog.internal.Changelog diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt similarity index 94% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt index e0a0813..1062abc 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import net.thunderbird.gradle.plugin.changelog.internal.ChangelogEntry diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt similarity index 85% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt index ec4bca1..7169277 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/Changelog.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal import kotlinx.datetime.LocalDate diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt similarity index 91% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt index d2f5ce1..ed75666 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManager.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt similarity index 80% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt index 12d7dda..7d8f764 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelper.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.fs import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt similarity index 54% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt index bf59ca6..1af9fa6 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/ConventionalCommit.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.git import net.thunderbird.gradle.plugin.changelog.internal.SectionType diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt similarity index 94% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt index c5dd54d..57a6f4f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClient.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.git import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt similarity index 90% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt index 5a84da3..2337942 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParser.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.git import net.thunderbird.gradle.plugin.changelog.internal.SectionType diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt similarity index 90% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt index ba9bd73..3b99eac 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParser.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.parser import net.thunderbird.gradle.plugin.changelog.internal.Changelog diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt similarity index 84% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt index 7fc248c..75f56bc 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/HeaderParser.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.parser import net.thunderbird.gradle.plugin.changelog.internal.ChangelogEntry diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt similarity index 93% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt index 5731912..436576c 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParser.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.parser import kotlinx.datetime.LocalDate diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt similarity index 63% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt index fb7c784..3413bec 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/ChangelogRenderer.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.render import net.thunderbird.gradle.plugin.changelog.internal.Changelog diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt similarity index 91% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt index 09e5cca..f2a7381 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRenderer.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.render import kotlinx.datetime.LocalDate diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt similarity index 83% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt index 24d23e4..dfed56e 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/dependency/check/DependencyCheckPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.dependency.check import com.github.benmanes.gradle.versions.updates.DependencyUpdatesTask diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt similarity index 91% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt index fe99d0a..35c635b 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/KotlinMultiplatformExtension.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.library.kmp import com.android.build.api.dsl.KotlinMultiplatformAndroidLibraryTarget diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt index 9c26209..52112bf 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/LibraryKmpPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.library.kmp import net.thunderbird.gradle.plugin.ProjectConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt similarity index 96% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt index c8e82de..993161b 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/library/kmp/compose/LibraryKmpComposePlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.library.kmp.compose import net.thunderbird.gradle.plugin.ProjectConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt similarity index 82% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt index 0359b27..ba6506f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinates.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.publishing import net.thunderbird.gradle.plugin.ProjectConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt index efec110..79ac1ef 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.publishing import com.vanniktech.maven.publish.MavenPublishBaseExtension diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt similarity index 88% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt index 1c9b75e..45a12e8 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/publishing/ValidatePublicationVersionTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.publishing import org.gradle.api.DefaultTask diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt similarity index 81% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt index 2807f41..ec1baa3 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoverageExtension.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.coverage import org.gradle.api.provider.Property diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt index 6ab4f81..d38e409 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/CodeCoveragePlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.coverage import kotlinx.kover.gradle.plugin.KoverGradlePlugin diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt similarity index 59% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt index ec0f0fb..5d08307 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/AndroidFilter.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.coverage.filter import kotlinx.kover.gradle.plugin.dsl.KoverReportFiltersConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt similarity index 60% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt index ca8b38a..937e5af 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/CommonFilter.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.coverage.filter import kotlinx.kover.gradle.plugin.dsl.KoverReportFiltersConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt similarity index 81% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt index 3be91db..f92a24f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/coverage/filter/ComposeFilter.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.coverage.filter import kotlinx.kover.gradle.plugin.dsl.KoverReportFiltersConfig diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt similarity index 93% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt index 545bf60..8f1e08f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/detekt/DetektPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.detekt import dev.detekt.gradle.Detekt diff --git a/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt new file mode 100644 index 0000000..8f96e42 --- /dev/null +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt @@ -0,0 +1,25 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ +package net.thunderbird.gradle.plugin.quality.spotless + +val kotlinEditorConfigOverride = mapOf( + "ktlint_code_style" to "intellij_idea", + "ktlint_ignore_back_ticked_identifier" to "true", + "ktlint_function_naming_ignore_when_annotated_with" to "Composable", + "ktlint_standard_class-signature" to "disabled", + "ktlint_standard_function-expression-body" to "disabled", + "ktlint_standard_function-signature" to "disabled", + "ktlint_standard_parameter-list-spacing" to "disabled", + "ktlint_standard_property-naming" to "disabled", +) + +val licenseHeaderMpl2 = """ + |/* + | * This Source Code Form is subject to the terms of the Mozilla Public + | * License, v. 2.0. If a copy of the MPL was not distributed with this + | * file, You can obtain one at https://mozilla.org/MPL/2.0/. + | */ +""".trimMargin() diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt similarity index 83% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt index ed8f335..f348fe5 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessPlugin.kt @@ -1,7 +1,11 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.quality.spotless import com.diffplug.gradle.spotless.SpotlessExtension -import kotlinEditorConfigOverride import org.gradle.api.Plugin import org.gradle.api.Project import org.gradle.kotlin.dsl.configure @@ -34,6 +38,8 @@ class SpotlessPlugin : Plugin { "src/*/kotlin/**/*.kt", ) + licenseHeader(licenseHeaderMpl2) + ktlint() .setEditorConfigPath(editorConfigPath) .editorConfigOverride(kotlinEditorConfigOverride) @@ -44,6 +50,8 @@ class SpotlessPlugin : Plugin { "*.gradle.kts", ) + licenseHeader(licenseHeaderMpl2, "(^(?![\\/ ]\\*).*$)") + ktlint() .setEditorConfigPath(editorConfigPath) .editorConfigOverride( @@ -76,9 +84,12 @@ class SpotlessPlugin : Plugin { kotlin { target( - "build-plugin/plugin/src/*/kotlin/*.kt", - "build-plugin/plugin/src/*/kotlin/**/*.kt", + "build-logic/plugin/src/*/kotlin/*.kt", + "build-logic/plugin/src/*/kotlin/**/*.kt", ) + + licenseHeader(licenseHeaderMpl2) + ktlint() .setEditorConfigPath(editorConfigPath) .editorConfigOverride(kotlinEditorConfigOverride) @@ -87,10 +98,12 @@ class SpotlessPlugin : Plugin { kotlinGradle { target( "*.gradle.kts", - "build-plugin/*.gradle.kts", - "build-plugin/plugin/*.gradle.kts", + "build-logic/*.gradle.kts", + "build-logic/plugin/*.gradle.kts", ) + licenseHeader(licenseHeaderMpl2, "(^(?![\\/ ]\\*).*$)") + ktlint() .setEditorConfigPath(editorConfigPath) .editorConfigOverride( diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt similarity index 92% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt index 7a8976c..64a8f12 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt similarity index 85% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt index 8d382c2..7816776 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import net.thunderbird.gradle.plugin.versioning.internal.VersionManager diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt similarity index 86% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt index 8f99e1d..dd1ee8d 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import net.thunderbird.gradle.plugin.versioning.internal.GitVersionReader diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt similarity index 89% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt index 873dadd..37504ff 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTask.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import net.thunderbird.gradle.plugin.versioning.internal.VersionManager diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt similarity index 95% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt index 208d03e..bb3ac0f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import net.thunderbird.gradle.plugin.versioning.internal.GitVersionProvider diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt similarity index 79% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt index 26b9668..6a53ed4 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionProvider.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt similarity index 84% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt index d6023c2..4ce6359 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReader.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt similarity index 74% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt index 4ed7238..0ee27e3 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolver.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt similarity index 87% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt index 301cab8..609fbb0 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriter.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt similarity index 53% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt index 8e0963a..6b1d8eb 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/ProviderBackedVersion.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import org.gradle.api.provider.Provider diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt similarity index 69% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt index a8d2cbc..5191655 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/Version.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal internal data class Version( diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt similarity index 92% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt index 6f4248d..366cbf3 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManager.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.io.File diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt similarity index 81% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt index e4320b5..e5f708e 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapper.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import java.util.Properties diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt similarity index 91% rename from build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt rename to build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt index 4124495..620ca7f 100644 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt +++ b/build-logic/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/wasm/WasmRepositoriesPlugin.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.wasm import org.gradle.api.Action diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt similarity index 92% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt index 2e27110..3f82d26 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/bom/BomPluginTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.bom import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt similarity index 95% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt index 7e3f027..d0785e1 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/ChangelogPluginTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt similarity index 96% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt index 9d840c9..c044660 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/FinalizeChangelogTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt similarity index 96% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt index 43b398e..d06b3b4 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/UpdateChangelogTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt similarity index 94% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt index c32d063..e34d3e0 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/WriteReleaseNotesTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt similarity index 88% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt index 0aa87dd..cba5cae 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/ChangelogManagerTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt similarity index 94% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt index c49daec..7e43ee2 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/fs/FileHelperTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.fs import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt similarity index 95% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt index 9f728b1..0fd8c0d 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitClientTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.git import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt similarity index 95% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt index 7ab6c1f..e47751a 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/git/GitConventionalCommitParserTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.git import assertk.all diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt similarity index 87% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt index 943be1d..e4f4155 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ChangelogParserTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.parser import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt similarity index 90% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt index 2f576e3..a7a776b 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/parser/ReleaseParserTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.parser import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt similarity index 88% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt index fe24c4c..a5f649f 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/changelog/internal/render/MarkdownChangelogRendererTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.changelog.internal.render import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt similarity index 93% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt index 6222623..faa5670 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingCoordinatesTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.publishing import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt similarity index 97% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt index 35738b9..4d68474 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/publishing/PublishingPluginTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.publishing import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt similarity index 94% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt index a4d7bb0..b8eae9d 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/CreateReleaseTagTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt similarity index 93% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt index 2fb41df..b24a96b 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintReleaseTagTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt similarity index 89% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt index cc84720..4b55d7d 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/PrintVersionTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt similarity index 95% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt index 67cfb08..04c6ef5 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersionBumpTaskTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt similarity index 96% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt index 903231c..ffe8652 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/VersioningPluginTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt similarity index 94% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt index 3b1c879..4159775 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionReaderTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt similarity index 87% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt index 3c60e69..38c12a0 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/GitVersionResolverTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt similarity index 89% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt index 157344b..4b3049c 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/PropertiesWriterTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt similarity index 95% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt index 6b9757a..54111ea 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionManagerTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertFailure diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt similarity index 90% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt index ebe1268..ca36694 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionPropertiesMapperTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertThat diff --git a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt similarity index 86% rename from build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt rename to build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt index ff24720..68b4b0a 100644 --- a/build-plugin/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt +++ b/build-logic/plugin/src/test/kotlin/net/thunderbird/gradle/plugin/versioning/internal/VersionTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.gradle.plugin.versioning.internal import assertk.assertThat diff --git a/build-plugin/settings.gradle.kts b/build-logic/settings.gradle.kts old mode 100755 new mode 100644 similarity index 60% rename from build-plugin/settings.gradle.kts rename to build-logic/settings.gradle.kts index e91b781..a3d8f7a --- a/build-plugin/settings.gradle.kts +++ b/build-logic/settings.gradle.kts @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ dependencyResolutionManagement { @Suppress("UnstableApiUsage") repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) @@ -14,6 +19,6 @@ dependencyResolutionManagement { } } -rootProject.name = "build-plugin" +rootProject.name = "build-logic" include(":plugin") diff --git a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt b/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt deleted file mode 100755 index 06e6820..0000000 --- a/build-plugin/plugin/src/main/kotlin/net/thunderbird/gradle/plugin/quality/spotless/SpotlessExtension.kt +++ /dev/null @@ -1,11 +0,0 @@ - -val kotlinEditorConfigOverride = mapOf( - "ktlint_code_style" to "intellij_idea", - "ktlint_ignore_back_ticked_identifier" to "true", - "ktlint_function_naming_ignore_when_annotated_with" to "Composable", - "ktlint_standard_class-signature" to "disabled", - "ktlint_standard_function-expression-body" to "disabled", - "ktlint_standard_function-signature" to "disabled", - "ktlint_standard_parameter-list-spacing" to "disabled", - "ktlint_standard_property-naming" to "disabled", -) diff --git a/build.gradle.kts b/build.gradle.kts index 04459ae..7c7bdae 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ plugins { alias(libs.plugins.android.application) apply false alias(libs.plugins.android.lint) apply false diff --git a/components/core/outcome/build.gradle.kts b/components/core/outcome/build.gradle.kts index 8b436eb..32f1bac 100644 --- a/components/core/outcome/build.gradle.kts +++ b/components/core/outcome/build.gradle.kts @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ plugins { alias(libs.plugins.tb.library.kmp) alias(libs.plugins.testBalloon) diff --git a/components/core/outcome/src/commonMain/kotlin/net/thunderbird/components/core/outcome/Outcome.kt b/components/core/outcome/src/commonMain/kotlin/net/thunderbird/components/core/outcome/Outcome.kt index 371cbe0..d6e84ea 100644 --- a/components/core/outcome/src/commonMain/kotlin/net/thunderbird/components/core/outcome/Outcome.kt +++ b/components/core/outcome/src/commonMain/kotlin/net/thunderbird/components/core/outcome/Outcome.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.components.core.outcome /** diff --git a/components/core/outcome/src/commonTest/kotlin/net/thunderbird/components/core/outcome/OutcomeTest.kt b/components/core/outcome/src/commonTest/kotlin/net/thunderbird/components/core/outcome/OutcomeTest.kt index bd13d64..ed1b1be 100644 --- a/components/core/outcome/src/commonTest/kotlin/net/thunderbird/components/core/outcome/OutcomeTest.kt +++ b/components/core/outcome/src/commonTest/kotlin/net/thunderbird/components/core/outcome/OutcomeTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.components.core.outcome import assertk.assertThat diff --git a/components/core/outcome/src/jvmTest/kotlin/net/thunderbird/components/core/outcome/OutcomeJvmCoverageTest.kt b/components/core/outcome/src/jvmTest/kotlin/net/thunderbird/components/core/outcome/OutcomeJvmCoverageTest.kt index c39d97e..2652168 100644 --- a/components/core/outcome/src/jvmTest/kotlin/net/thunderbird/components/core/outcome/OutcomeJvmCoverageTest.kt +++ b/components/core/outcome/src/jvmTest/kotlin/net/thunderbird/components/core/outcome/OutcomeJvmCoverageTest.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.components.core.outcome import assertk.assertThat diff --git a/quality/konsist/build.gradle.kts b/quality/konsist/build.gradle.kts index 0396974..f300bde 100644 --- a/quality/konsist/build.gradle.kts +++ b/quality/konsist/build.gradle.kts @@ -1,5 +1,11 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ plugins { id("org.jetbrains.kotlin.jvm") + alias(libs.plugins.tb.quality.spotless) } kotlin { diff --git a/quality/konsist/src/test/kotlin/net/thunderbird/quality/Scope.kt b/quality/konsist/src/test/kotlin/net/thunderbird/quality/Scope.kt index e14a708..20d59ee 100644 --- a/quality/konsist/src/test/kotlin/net/thunderbird/quality/Scope.kt +++ b/quality/konsist/src/test/kotlin/net/thunderbird/quality/Scope.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.quality import com.lemonappdev.konsist.api.Konsist diff --git a/quality/konsist/src/test/kotlin/net/thunderbird/quality/ValidateLogger.kt b/quality/konsist/src/test/kotlin/net/thunderbird/quality/ValidateLogger.kt index 69ef35d..208a535 100644 --- a/quality/konsist/src/test/kotlin/net/thunderbird/quality/ValidateLogger.kt +++ b/quality/konsist/src/test/kotlin/net/thunderbird/quality/ValidateLogger.kt @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ package net.thunderbird.quality import com.lemonappdev.konsist.api.verify.assertFalse @@ -9,7 +14,8 @@ class ValidateLogger { fun `no class should use Java util logging`() { projectScope.files .assertFalse( - additionalMessage = "No class should use java.util.logging import, use net.thunderbird.core.logging.Logger instead." + additionalMessage = "No class should use java.util.logging import, " + + "use net.thunderbird.core.logging.Logger instead.", ) { it.hasImport { import -> import.name == "java.util.logging.." } } } @@ -18,7 +24,8 @@ class ValidateLogger { projectScope.files .filterNot { it.hasNameMatching("ConsoleLogSinkTest.android".toRegex()) } .assertFalse( - additionalMessage = "No class should use android.util.Log import, use net.thunderbird.core.logging.Logger instead." + additionalMessage = "No class should use android.util.Log import, " + + "use net.thunderbird.core.logging.Logger instead.", ) { it.hasImport { import -> import.name == "android.util.Log" } } @@ -27,13 +34,17 @@ class ValidateLogger { @Test fun `no class should use Timber logging`() { projectScope.files - .filterNot { it.hasNameMatching("ConsoleLogSink.android|ConsoleLogSinkTest.android|PlatformInitializer.android".toRegex()) } .filterNot { + it.hasNameMatching( + "ConsoleLogSink.android|ConsoleLogSinkTest.android|PlatformInitializer.android".toRegex(), + ) + }.filterNot { // Exclude legacy code that still uses Timber it.hasNameMatching("LogFileWriter|FileLoggerTree|K9".toRegex()) } .assertFalse( - additionalMessage = "No class should use timber.log.Timber import, use net.thunderbird.core.logging.Logger instead." + additionalMessage = "No class should use timber.log.Timber import, " + + "use net.thunderbird.core.logging.Logger instead.", ) { it.hasImport { import -> import.name == "timber.log.Timber" } } } } diff --git a/settings.gradle.kts b/settings.gradle.kts index e17c84a..c34613a 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -1,3 +1,8 @@ +/* + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. + */ // Thunderbird Mobile Components rootProject.name = "tmc" enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS") @@ -15,7 +20,7 @@ pluginManagement { gradlePluginPortal() } - includeBuild("build-plugin") + includeBuild("build-logic") } dependencyResolutionManagement {