From 410d22e73cae6fcae31271bcc60af406aa1aa1a6 Mon Sep 17 00:00:00 2001 From: John Dennis Casey Date: Sun, 25 Sep 2005 14:49:27 +0000 Subject: [PATCH] Rolling back the release plugin's dependencies to -beta-1 of maven, and making resolvePluginVersion(..) with the flag for processAsReport public again with deprecation, so the release plugin continues to function into the next release. git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@291420 13f79535-47bb-0310-9956-ffa450edef68 --- .../plugin/version/DefaultPluginVersionManager.java | 5 ++++- .../maven/plugin/version/PluginVersionManager.java | 7 +++++++ maven-plugins/maven-release-plugin/pom.xml | 10 +++++----- .../maven/plugins/release/PrepareReleaseMojo.java | 4 ++-- 4 files changed, 18 insertions(+), 8 deletions(-) diff --git a/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java b/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java index 0da20ccccf..9da5bdda98 100644 --- a/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java +++ b/maven-core/src/main/java/org/apache/maven/plugin/version/DefaultPluginVersionManager.java @@ -87,7 +87,10 @@ public class DefaultPluginVersionManager return resolvePluginVersion( groupId, artifactId, project, settings, localRepository, true ); } - private String resolvePluginVersion( String groupId, String artifactId, MavenProject project, Settings settings, + /** + * @deprecated Make private, use resolveReportPluginVersion(..) or resolvePluginVersion(..) instead. + */ + public String resolvePluginVersion( String groupId, String artifactId, MavenProject project, Settings settings, ArtifactRepository localRepository, boolean resolveAsReportPlugin ) throws PluginVersionResolutionException { diff --git a/maven-core/src/main/java/org/apache/maven/plugin/version/PluginVersionManager.java b/maven-core/src/main/java/org/apache/maven/plugin/version/PluginVersionManager.java index a2a05802be..e899b47db7 100644 --- a/maven-core/src/main/java/org/apache/maven/plugin/version/PluginVersionManager.java +++ b/maven-core/src/main/java/org/apache/maven/plugin/version/PluginVersionManager.java @@ -28,6 +28,13 @@ public interface PluginVersionManager ArtifactRepository localRepository ) throws PluginVersionResolutionException; + /** + * @deprecated Use resolveReportPluginVersion(..) instead. + */ + String resolvePluginVersion( String groupId, String artifactId, MavenProject project, Settings settings, + ArtifactRepository localRepository, boolean processAsReport ) + throws PluginVersionResolutionException; + String resolveReportPluginVersion( String groupId, String artifactId, MavenProject project, Settings settings, ArtifactRepository localRepository ) throws PluginVersionResolutionException; diff --git a/maven-plugins/maven-release-plugin/pom.xml b/maven-plugins/maven-release-plugin/pom.xml index 36d1c9ba96..fc8031a09b 100644 --- a/maven-plugins/maven-release-plugin/pom.xml +++ b/maven-plugins/maven-release-plugin/pom.xml @@ -2,7 +2,7 @@ maven-plugin-parent org.apache.maven.plugins - 2.0-beta-2-SNAPSHOT + 2.0-beta-1 4.0.0 maven-release-plugin @@ -13,12 +13,12 @@ org.apache.maven maven-core - 2.0-beta-2-SNAPSHOT + 2.0-beta-1 org.apache.maven maven-artifact - 2.0-beta-2-SNAPSHOT + 2.0-beta-1 org.apache.maven.scm @@ -42,12 +42,12 @@ org.apache.maven maven-artifact-manager - 2.0-beta-2-SNAPSHOT + 2.0-beta-1 org.apache.maven maven-artifact - 2.0-beta-2-SNAPSHOT + 2.0-beta-1 org.apache.maven.scm diff --git a/maven-plugins/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java b/maven-plugins/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java index d6c65262bc..1404a52e22 100644 --- a/maven-plugins/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java +++ b/maven-plugins/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java @@ -961,8 +961,8 @@ public class PrepareReleaseMojo String version; try { - version = pluginVersionManager.resolveReportPluginVersion( plugin.getGroupId(), plugin - .getArtifactId(), project, settings, localRepository ); + version = pluginVersionManager.resolvePluginVersion( plugin.getGroupId(), plugin + .getArtifactId(), project, settings, localRepository, true ); } catch ( PluginVersionResolutionException e ) {