diff --git a/build-logic/build.gradle.kts b/build-logic/build.gradle.kts index 9a0234a..f18384d 100644 --- a/build-logic/build.gradle.kts +++ b/build-logic/build.gradle.kts @@ -46,7 +46,7 @@ spotless { endWithNewline() encoding("UTF-8") toggleOffOn() - target("*.gradle.kts") + target("**/*.gradle.kts") } kotlinGradle { applyCommon() diff --git a/build-logic/src/main/kotlin/base-conventions.gradle.kts b/build-logic/src/main/kotlin/base-conventions.gradle.kts index f3bb571..23e9d3a 100644 --- a/build-logic/src/main/kotlin/base-conventions.gradle.kts +++ b/build-logic/src/main/kotlin/base-conventions.gradle.kts @@ -56,4 +56,4 @@ tasks { register("cleanAll", Delete::class) { dependsOn("clean", "cleanIdea", "cleanVisualStudio", "cleanEclipse") } -} \ No newline at end of file +} diff --git a/build-logic/src/main/kotlin/common-conventions.gradle.kts b/build-logic/src/main/kotlin/common-conventions.gradle.kts index 7d8e174..85c0f72 100644 --- a/build-logic/src/main/kotlin/common-conventions.gradle.kts +++ b/build-logic/src/main/kotlin/common-conventions.gradle.kts @@ -14,7 +14,7 @@ plugins { id("java-library") } -//val libs = extensions.getByType(org.gradle.accessors.dm.LibrariesForLibs::class) +// val libs = extensions.getByType(org.gradle.accessors.dm.LibrariesForLibs::class) extensions.getByType(BasePluginExtension::class.java).archivesName.set(project.nameString(true)) @@ -62,9 +62,10 @@ indraSpotlessLicenser { headerFormat(HeaderFormat.starSlash()) licenseHeaderFile(rootProject.projectDir.resolve("HEADER")) - val currentYear = Calendar.getInstance().apply { - time = Date() - }.get(Calendar.YEAR) + val currentYear = + Calendar.getInstance().apply { + time = Date() + }.get(Calendar.YEAR) val createdYear = providers.gradleProperty("createdYear").map { it.toInt() }.getOrElse(currentYear) val year = if (createdYear == currentYear) createdYear.toString() else "$createdYear-$currentYear" @@ -72,7 +73,6 @@ indraSpotlessLicenser { property("year", year) property("description", project.description ?: "A template project") property("author", providers.gradleProperty("projectAuthor").getOrElse("template")) - } tasks { @@ -92,8 +92,8 @@ tasks { mergeServiceFiles() transform(Log4j2PluginsCacheFileTransformer::class.java) - relocate("xyz.jpenilla.gremlin", "dev.mizule.timetriggeredperms.lib.xyz.jpenilla.gremlin") - relocate("org.bstats", "dev.mizule.timetriggeredperms.lib.org.bstats") + relocate("xyz.jpenilla.gremlin", "dev.mizule.timetriggeredperms.lib.xyz.jpenilla.gremlin") + relocate("org.bstats", "dev.mizule.timetriggeredperms.lib.org.bstats") } withType().configureEach { @@ -108,12 +108,13 @@ tasks { filteringCharset = "UTF-8" duplicatesStrategy = DuplicatesStrategy.INCLUDE - val praps = mapOf( - "pluginVersion" to project.versionString(), - "pluginAuthor" to providers.gradleProperty("projectAuthor").getOrElse("template"), - "pluginName" to providers.gradleProperty("projectName").getOrElse("template"), - "pluginDescription" to (project.description ?: "A template project") - ) + val praps = + mapOf( + "pluginVersion" to project.versionString(), + "pluginAuthor" to providers.gradleProperty("projectAuthor").getOrElse("template"), + "pluginName" to providers.gradleProperty("projectName").getOrElse("template"), + "pluginDescription" to (project.description ?: "A template project"), + ) filesMatching(setOf("paper-plugin.yml", "plugin.yml", "velocity-plugin.json")) { expand(praps) diff --git a/build-logic/src/main/kotlin/kotlin-conventions.gradle.kts b/build-logic/src/main/kotlin/kotlin-conventions.gradle.kts index 125d8cf..8f0f434 100644 --- a/build-logic/src/main/kotlin/kotlin-conventions.gradle.kts +++ b/build-logic/src/main/kotlin/kotlin-conventions.gradle.kts @@ -19,4 +19,4 @@ tasks { extensions.configure(KotlinProjectExtension::class) { jvmToolchain(17) -} \ No newline at end of file +} diff --git a/build-logic/src/main/kotlin/paper-conventions.gradle.kts b/build-logic/src/main/kotlin/paper-conventions.gradle.kts index a052dad..5c3af29 100644 --- a/build-logic/src/main/kotlin/paper-conventions.gradle.kts +++ b/build-logic/src/main/kotlin/paper-conventions.gradle.kts @@ -47,4 +47,4 @@ hangarPublish { resourcePage(provider { rootProject.file("README.md").readText() }) } } -} \ No newline at end of file +} diff --git a/build-logic/src/main/kotlin/parent-conventions.gradle.kts b/build-logic/src/main/kotlin/parent-conventions.gradle.kts index 9f7b6c7..298ce08 100644 --- a/build-logic/src/main/kotlin/parent-conventions.gradle.kts +++ b/build-logic/src/main/kotlin/parent-conventions.gradle.kts @@ -1,3 +1,3 @@ plugins { base -} \ No newline at end of file +}