From a197ada6eb54ba89037a04c9d24ee1faab82aa80 Mon Sep 17 00:00:00 2001 From: Michael Osipov Date: Wed, 20 Jul 2022 20:23:12 +0200 Subject: [PATCH] [MRELEASE-1100] Upgrade Maven SCM to 2.0.0-M2 This closes #143 --- .../apache/maven/shared/release/stubs/ScmManagerStub.java | 2 -- .../apache/maven/scm/provider/stub/StubCheckInCommand.java | 6 +++--- .../apache/maven/scm/provider/stub/StubCheckOutCommand.java | 6 +++--- .../org/apache/maven/scm/provider/stub/StubScmProvider.java | 4 +--- .../org/apache/maven/scm/provider/stub/StubTagCommand.java | 6 +++--- pom.xml | 2 +- 6 files changed, 11 insertions(+), 15 deletions(-) diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/stubs/ScmManagerStub.java b/maven-release-manager/src/test/java/org/apache/maven/shared/release/stubs/ScmManagerStub.java index e7a82530d..99d6b389a 100644 --- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/stubs/ScmManagerStub.java +++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/stubs/ScmManagerStub.java @@ -19,7 +19,6 @@ * under the License. */ -import javax.inject.Named; import javax.inject.Singleton; import java.util.HashMap; @@ -34,7 +33,6 @@ * Override the makeRepository methods to honour the URL passed in. */ @Singleton -@Named( "default" ) @Priority( 100 ) public class ScmManagerStub extends org.apache.maven.scm.manager.ScmManagerStub diff --git a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckInCommand.java b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckInCommand.java index 22c6d8af3..25e1abcc3 100644 --- a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckInCommand.java +++ b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckInCommand.java @@ -38,7 +38,7 @@ /** * A dummy check-in command. - * + * * @author Benjamin Bentmann */ class StubCheckInCommand @@ -58,7 +58,7 @@ protected ScmResult executeCommand( ScmProviderRepository repository, ScmFileSet File workingCopyRoot = stubRepo.getWorkingCopyRoot( fileSet ); File repoRoot = stubRepo.getRoot(); - getLogger().info( "Committing: " + workingCopyRoot + " > " + repoRoot ); + logger.info( "Committing: " + workingCopyRoot + " > " + repoRoot ); List paths = stubRepo.getPaths( workingCopyRoot, fileSet ); @@ -68,7 +68,7 @@ protected ScmResult executeCommand( ScmProviderRepository repository, ScmFileSet File srcFile = new File( workingCopyRoot, path ); File dstFile = new File( repoRoot, path ); - getLogger().info( " " + path ); + logger.info( " " + path ); if ( dstFile.isDirectory() ) { diff --git a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckOutCommand.java b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckOutCommand.java index 9296f4f4a..4b86c1ac1 100644 --- a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckOutCommand.java +++ b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubCheckOutCommand.java @@ -42,7 +42,7 @@ /** * A dummy check-out command. - * + * * @author Benjamin Bentmann */ class StubCheckOutCommand @@ -75,7 +75,7 @@ else if ( version instanceof ScmBranch ) revRoot = stubRepo.getRoot(); } - getLogger().info( "Checking out: " + revRoot + " > " + workingCopyRoot ); + logger.info( "Checking out: " + revRoot + " > " + workingCopyRoot ); if ( workingCopyRoot.isFile() ) { @@ -100,7 +100,7 @@ else if ( version instanceof ScmBranch ) File srcFile = new File( revRoot, path ); File dstFile = new File( workingCopyRoot, path ); - getLogger().info( " " + path ); + logger.info( " " + path ); if ( srcFile.isDirectory() ) { diff --git a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubScmProvider.java b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubScmProvider.java index 19ff57c49..890cb3698 100644 --- a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubScmProvider.java +++ b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubScmProvider.java @@ -38,7 +38,7 @@ /** * A stub SCM provider used for the Maven Release Plugin when doing integration testing. - * + * * @author Benjamin Bentmann */ @Singleton @@ -62,8 +62,6 @@ protected ScmResult executeCommand( Command command, ScmProviderRepository repos CommandParameters parameters ) throws ScmException { - command.setLogger( getLogger() ); - return command.execute( repository, fileSet, parameters ); } diff --git a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubTagCommand.java b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubTagCommand.java index 537e026a4..d53958dd7 100644 --- a/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubTagCommand.java +++ b/maven-release-plugin/src/it/setup/maven-scm-provider-stub/src/main/java/org/apache/maven/scm/provider/stub/StubTagCommand.java @@ -39,7 +39,7 @@ /** * A dummy tag command. - * + * * @author Benjamin Bentmann */ class StubTagCommand @@ -61,7 +61,7 @@ protected ScmResult executeCommand( ScmProviderRepository repository, ScmFileSet String tagName = parameters.getString( CommandParameter.TAG_NAME ); File tagRoot = new File( stubRepo.getTagBase(), tagName ); - getLogger().info( "Tagging: " + repoRoot + " > " + tagRoot ); + logger.info( "Tagging: " + repoRoot + " > " + tagRoot ); if ( tagRoot.exists() ) { @@ -80,7 +80,7 @@ protected ScmResult executeCommand( ScmProviderRepository repository, ScmFileSet File srcFile = new File( repoRoot, path ); File dstFile = new File( tagRoot, path ); - getLogger().info( " " + path ); + logger.info( " " + path ); if ( srcFile.isDirectory() ) { diff --git a/pom.xml b/pom.xml index d416745e7..536335d9f 100644 --- a/pom.xml +++ b/pom.xml @@ -90,7 +90,7 @@ - 1.13.0 + 2.0.0-M2 8 3.2.5 1.0.0.v20140518