From 2a294b9d0dbd34c402683fd3d74c2ea373f62842 Mon Sep 17 00:00:00 2001 From: Vladimir Sitnikov Date: Fri, 10 Feb 2023 19:13:50 +0300 Subject: [PATCH] Add forbidden-apis check to prevent accidental use of locale-dependent APIs See https://github.com/policeman-tools/forbidden-apis/wiki/BundledSignatures See https://github.com/policeman-tools/forbidden-apis/wiki/GradleUsage Fixes https://github.com/gradlex-org/build-parameters/issues/91 --- build.gradle.kts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/build.gradle.kts b/build.gradle.kts index cdecab1..822f4ba 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -3,6 +3,7 @@ plugins { id("gradlexbuild.build-parameters") id("gradlexbuild.documentation-conventions") id("org.gradlex.internal.plugin-publish-conventions") version "0.5" + id("de.thetaphi.forbiddenapis") version "3.4" } group = "org.gradlex" @@ -50,3 +51,7 @@ tasks.publishPlugins { dependsOn(tasks.check) } +forbiddenApis { + // See https://github.com/policeman-tools/forbidden-apis/wiki/BundledSignatures + bundledSignatures.add("jdk-unsafe") +}