From bb16ab20e838d80115f7a41bea595a8ab4abb7d8 Mon Sep 17 00:00:00 2001 From: "Daniel A. A. Pelsmaeker" Date: Wed, 10 Jul 2024 15:17:53 +0200 Subject: [PATCH] Silence more warnings --- .../kotlin/org/metaborg/convention/JavaConventionPlugin.kt | 5 ++++- .../org/metaborg/convention/MavenPublishConventionPlugin.kt | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/convention-plugin/src/main/kotlin/org/metaborg/convention/JavaConventionPlugin.kt b/convention-plugin/src/main/kotlin/org/metaborg/convention/JavaConventionPlugin.kt index 0e733cb..8b30456 100644 --- a/convention-plugin/src/main/kotlin/org/metaborg/convention/JavaConventionPlugin.kt +++ b/convention-plugin/src/main/kotlin/org/metaborg/convention/JavaConventionPlugin.kt @@ -66,8 +66,11 @@ class JavaConventionPlugin: Plugin { // Use UTF-8 encoding by default encoding = "UTF-8" charset("UTF-8") - // Silence doclint warnings + // Reduce doclint warnings + addStringOption("Xmaxwarns", "1") + // Silence doclint lints addStringOption("Xdoclint:none", "-quiet") + // Silence! quiet() } } diff --git a/convention-plugin/src/main/kotlin/org/metaborg/convention/MavenPublishConventionPlugin.kt b/convention-plugin/src/main/kotlin/org/metaborg/convention/MavenPublishConventionPlugin.kt index 5dc72f7..e20f6cf 100644 --- a/convention-plugin/src/main/kotlin/org/metaborg/convention/MavenPublishConventionPlugin.kt +++ b/convention-plugin/src/main/kotlin/org/metaborg/convention/MavenPublishConventionPlugin.kt @@ -94,6 +94,7 @@ class MavenPublishConventionPlugin: Plugin { // Configure publishing to GitHub Packages maven { name = GITHUB_PACKAGES_PUBLICATION_NAME + // NOTE: If repoOwner or repoName are not specified, this will fail. In that case we can't configure GitHub Packages url = with(extension.repoOwner, extension.repoName) { owner, name -> uri("https://maven.pkg.github.com/$owner/$name") }.get() credentials { username = project.findProperty("gpr.user") as String? ?: System.getenv("GITHUB_ACTOR")