From 020c53c7bd4e3e537ec51a139f244178e6deb982 Mon Sep 17 00:00:00 2001 From: Ibragimov Ruslan <493656+IRus@users.noreply.github.com> Date: Mon, 13 May 2024 10:41:02 +0300 Subject: [PATCH 1/3] Remove deprecated property use --- src/main/groovy/net/researchgate/release/ReleasePlugin.groovy | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy index a8c91163..9bfd1879 100644 --- a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy +++ b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy @@ -104,7 +104,6 @@ class ReleasePlugin extends PluginHelper implements Plugin { startParameter.projectProperties.putAll(project.getGradle().startParameter.projectProperties) startParameter.projectProperties.put('release.releasing', "true") startParameter.projectDir = project.projectDir - startParameter.settingsFile = project.getGradle().startParameter.settingsFile startParameter.gradleUserHomeDir = project.getGradle().startParameter.gradleUserHomeDir buildName = project.name From de5ca596530e01c93c0308d98e32ea2fc4dee2dc Mon Sep 17 00:00:00 2001 From: Ruslan Ibragimov Date: Mon, 8 Jul 2024 11:09:34 +0300 Subject: [PATCH 2/3] Add Gradle version check to prevent usage of deprecated settingsFile property --- src/main/groovy/net/researchgate/release/ReleasePlugin.groovy | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy index 9bfd1879..507deaf5 100644 --- a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy +++ b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy @@ -104,6 +104,10 @@ class ReleasePlugin extends PluginHelper implements Plugin { startParameter.projectProperties.putAll(project.getGradle().startParameter.projectProperties) startParameter.projectProperties.put('release.releasing', "true") startParameter.projectDir = project.projectDir + if (GradleVersion.current() < GradleVersion.version("9.0")) { + // Setting custom settings file for the build has been deprecated. + startParameter.settingsFile = project.getGradle().startParameter.settingsFile + } startParameter.gradleUserHomeDir = project.getGradle().startParameter.gradleUserHomeDir buildName = project.name From 1a6326120d5dbcd55267fdf3b3b782d48e67d4cc Mon Sep 17 00:00:00 2001 From: Ruslan Ibragimov Date: Mon, 8 Jul 2024 11:16:10 +0300 Subject: [PATCH 3/3] Add Gradle version check to prevent usage of deprecated settingsFile property --- src/main/groovy/net/researchgate/release/ReleasePlugin.groovy | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy index 507deaf5..20c45b9b 100644 --- a/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy +++ b/src/main/groovy/net/researchgate/release/ReleasePlugin.groovy @@ -31,6 +31,7 @@ import org.gradle.api.Task import org.gradle.api.plugins.BasePlugin import org.gradle.api.tasks.GradleBuild import org.gradle.api.tasks.TaskState +import org.gradle.util.GradleVersion class ReleasePlugin extends PluginHelper implements Plugin {