[maven-release] branch master updated: Clean up code, no implementation changes

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[maven-release] branch master updated: Clean up code, no implementation changes

rfscholte
This is an automated email from the ASF dual-hosted git repository.

rfscholte pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-release.git


The following commit(s) were added to refs/heads/master by this push:
     new a046f0a  Clean up code, no implementation changes
a046f0a is described below

commit a046f0afce9c01138f54ba4201bb7b57d8980a3c
Author: rfscholte <[hidden email]>
AuthorDate: Fri Jan 12 11:53:16 2018 +0100

    Clean up code, no implementation changes
---
 .../maven/plugins/release/AbstractReleaseMojo.java       |  8 ++++----
 .../maven/plugins/release/AbstractScmReleaseMojo.java    | 14 ++++++--------
 .../apache/maven/plugins/release/BranchReleaseMojo.java  |  8 +++-----
 .../apache/maven/plugins/release/CleanReleaseMojo.java   |  5 +----
 .../apache/maven/plugins/release/PerformReleaseMojo.java |  8 ++------
 .../apache/maven/plugins/release/PrepareReleaseMojo.java |  9 ++++-----
 .../maven/plugins/release/PrepareWithPomReleaseMojo.java |  3 ++-
 .../maven/plugins/release/RollbackReleaseMojo.java       |  5 +----
 .../apache/maven/plugins/release/StageReleaseMojo.java   |  4 ++--
 .../apache/maven/plugins/release/UpdateVersionsMojo.java | 16 +++++++---------
 10 files changed, 32 insertions(+), 48 deletions(-)

diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractReleaseMojo.java
index ab1fb11..faa9805 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractReleaseMojo.java
@@ -176,7 +176,7 @@ public abstract class AbstractReleaseMojo
                     args += ",";
                 }
             }
-            
+
             if ( additionalProfiles != null )
             {
                 if ( !profileIds.isEmpty() )
@@ -192,7 +192,7 @@ public abstract class AbstractReleaseMojo
     }
 
     /**
-     *
+     *
      * @return a List with profile ids, never {@code null}
      */
     @SuppressWarnings( "unchecked" )
@@ -215,7 +215,7 @@ public abstract class AbstractReleaseMojo
             }
             else
             {
-                profiles = new ArrayList<String>( project.getActiveProfiles().size() );
+                profiles = new ArrayList<>( project.getActiveProfiles().size() );
                 for ( Object profile : project.getActiveProfiles() )
                 {
                     profiles.add( ( (Profile) profile ).getId() );
@@ -254,7 +254,7 @@ public abstract class AbstractReleaseMojo
     {
         return settings;
     }
-    
+
     protected final File getBasedir()
     {
         return basedir;
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractScmReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractScmReleaseMojo.java
index 87aca4a..b57aab4 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractScmReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/AbstractScmReleaseMojo.java
@@ -29,8 +29,8 @@ import org.apache.maven.scm.manager.ScmManager;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
 
 /**
- * Abstract Mojo containing SCM parameters
- *  
+ * Abstract Mojo containing SCM parameters
+ *
  * @author Robert Scholte
  */
 // Extra layer since 2.4. Don't use @since doclet, these would be inherited by the subclasses
@@ -95,7 +95,7 @@ public abstract class AbstractScmReleaseMojo
     private boolean pushChanges = true;
 
     /**
-     * Add a new or overwrite the default implementation per provider.
+     * Add a new or overwrite the default implementation per provider.
      * The key is the scm prefix and the value is the role hint of the
      * {@link org.apache.maven.scm.provider.ScmProvider}.
      *
@@ -104,16 +104,14 @@ public abstract class AbstractScmReleaseMojo
      */
     @Parameter
     private Map<String, String> providerImplementations;
-    
+
     /**
      * The SCM manager.
      */
     @Component
     private ScmManager scmManager;
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
@@ -127,7 +125,7 @@ public abstract class AbstractScmReleaseMojo
             }
         }
     }
-    
+
     @Override
     protected ReleaseDescriptor createReleaseDescriptor()
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/BranchReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/BranchReleaseMojo.java
index 4a429a2..1ba1a46 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/BranchReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/BranchReleaseMojo.java
@@ -191,7 +191,7 @@ public class BranchReleaseMojo
     private String developmentVersion;
 
     /**
-     * The role-hint for the {@link org.apache.maven.shared.release.policy.version.VersionPolicy}
+     * The role-hint for the {@link org.apache.maven.shared.release.policy.version.VersionPolicy}
      * implementation used to calculate the project versions.
      *
      * @since 3.0.0
@@ -201,7 +201,7 @@ public class BranchReleaseMojo
     private String projectVersionPolicyId;
 
     /**
-     * The role-hint for the {@link org.apache.maven.shared.release.policy.naming.NamingPolicy}
+     * The role-hint for the {@link org.apache.maven.shared.release.policy.naming.NamingPolicy}
      * implementation used to calculate the project names.
      *
      * @since 3.0.0
@@ -210,9 +210,7 @@ public class BranchReleaseMojo
     @Parameter( property = "projectNamingPolicyId" )
     private String projectBranchNamingPolicyId;
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/CleanReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/CleanReleaseMojo.java
index 0dc7b79..bd77143 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/CleanReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/CleanReleaseMojo.java
@@ -38,10 +38,7 @@ import org.apache.maven.shared.release.config.ReleaseDescriptor;
 public class CleanReleaseMojo
     extends AbstractReleaseMojo
 {
-
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PerformReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PerformReleaseMojo.java
index c34eef5..4826f78 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PerformReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PerformReleaseMojo.java
@@ -135,17 +135,13 @@ public class PerformReleaseMojo
     @Component
     private ScmManager scmManager;
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     protected String getAdditionalProfiles()
     {
         return releaseProfiles;
     }
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java
index 901d8c4..80dc9bd 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareReleaseMojo.java
@@ -58,6 +58,7 @@ public class PrepareReleaseMojo
     /**
      * @deprecated Please use release:prepare-with-pom instead.
      */
+    @Deprecated
     @Parameter( defaultValue = "false", property = "generateReleasePoms" )
     private boolean generateReleasePoms;
 
@@ -218,7 +219,7 @@ public class PrepareReleaseMojo
     private int waitBeforeTagging;
 
     /**
-     * The role-hint for the {@link org.apache.maven.shared.release.policy.version.VersionPolicy}
+     * The role-hint for the {@link org.apache.maven.shared.release.policy.version.VersionPolicy}
      * implementation used to calculate the project versions.
      *
      * @since 2.5.1
@@ -228,7 +229,7 @@ public class PrepareReleaseMojo
     private String projectVersionPolicyId;
 
     /**
-     * The role-hint for the {@link org.apache.maven.shared.release.policy.naming.NamingPolicy}
+     * The role-hint for the {@link org.apache.maven.shared.release.policy.naming.NamingPolicy}
      * implementation used to calculate the project branch and tag names.
      *
      * @since 3.0.0
@@ -237,9 +238,7 @@ public class PrepareReleaseMojo
     @Parameter( property = "projectNamingPolicyId" )
     private String projectTagNamingPolicyId;
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareWithPomReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareWithPomReleaseMojo.java
index 409c89e..b56eb0d 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareWithPomReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/PrepareWithPomReleaseMojo.java
@@ -27,7 +27,7 @@ import org.apache.maven.plugins.annotations.ResolutionScope;
 
 /**
  * Prepare for a release in SCM, fully resolving dependencies for the purpose of producing a "release POM".
- *
+ *
  * @author <a href="mailto:[hidden email]">Brett Porter</a>
  * @since 2.0
  */
@@ -41,6 +41,7 @@ public class PrepareWithPomReleaseMojo
     @Parameter( defaultValue = "true", property = "generateReleasePoms" )
     private boolean generateReleasePoms;
 
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/RollbackReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/RollbackReleaseMojo.java
index fd0cad0..57f1a05 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/RollbackReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/RollbackReleaseMojo.java
@@ -40,10 +40,7 @@ import org.apache.maven.shared.release.config.ReleaseDescriptor;
 public class RollbackReleaseMojo
     extends AbstractScmReleaseMojo
 {
-
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/StageReleaseMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/StageReleaseMojo.java
index c0a5a04..a92b7b3 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/StageReleaseMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/StageReleaseMojo.java
@@ -31,7 +31,7 @@ import org.codehaus.plexus.util.StringUtils;
  *
  * If the goals contain <code>site-deploy</code> or <code>site:deploy</code>, these
  * are overridden with <code>site:stage-deploy</code>.
- *
+ *
  * @author <a href="mailto:[hidden email]">Nicolas De Loof</a>
  * @version $Id$
  * @since 2.0-beta-8
@@ -42,7 +42,7 @@ public class StageReleaseMojo
 {
     /**
      * URL of the staging repository to use.
-     *
+     *
      * @since 2.0-beta-8
      */
     @Parameter( property = "stagingRepository", required = true )
diff --git a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/UpdateVersionsMojo.java b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/UpdateVersionsMojo.java
index e3ebb92..04d04b8 100644
--- a/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/UpdateVersionsMojo.java
+++ b/maven-release-plugin/src/main/java/org/apache/maven/plugins/release/UpdateVersionsMojo.java
@@ -38,7 +38,7 @@ import org.apache.maven.shared.release.config.ReleaseUtils;
  * without making other modifications to the SCM such as tagging. For more info see <a
  * href="http://maven.apache.org/plugins/maven-release-plugin/examples/update-versions.html"
  * >http://maven.apache.org/plugins/maven-release-plugin/examples/update-versions.html</a>.
- *
+ *
  * @author Paul Gier
  * @version $Id$
  * @since 2.0
@@ -51,7 +51,7 @@ public class UpdateVersionsMojo
     /**
      * Whether to automatically assign submodules the parent version. If set to false, the user will be prompted for the
      * version of each submodules.
-     *
+     *
      * @since 2.0
      */
     @Parameter( defaultValue = "false", property = "autoVersionSubmodules" )
@@ -59,7 +59,7 @@ public class UpdateVersionsMojo
 
     /**
      * Whether to add a schema to the POM if it was previously missing on release.
-     *
+     *
      * @since 2.0
      */
     @Parameter( defaultValue = "true", property = "addSchema" )
@@ -67,7 +67,7 @@ public class UpdateVersionsMojo
 
     /**
      * Default version to use for new local working copy.
-     *
+     *
      * @since 2.0
      */
     @Parameter( property = "developmentVersion" )
@@ -83,7 +83,7 @@ public class UpdateVersionsMojo
 
     /**
      * Whether to use "edit" mode on the SCM, to lock the file for editing during SCM operations.
-     *
+     *
      * @since 2.5.2
      */
     @Parameter( defaultValue = "false", property = "useEditMode" )
@@ -97,9 +97,7 @@ public class UpdateVersionsMojo
     @Parameter( defaultValue = "default", property = "projectVersionPolicyId" )
     private String projectVersionPolicyId;
 
-    /**
-     * {@inheritDoc}
-     */
+    @Override
     public void execute()
         throws MojoExecutionException, MojoFailureException
     {
@@ -111,7 +109,7 @@ public class UpdateVersionsMojo
         config.setUpdateDependencies( updateDependencies );
         config.setProjectVersionPolicyId( projectVersionPolicyId );
 
-        Map<String, Scm> originalScmInfo = new HashMap<String, Scm>();
+        Map<String, Scm> originalScmInfo = new HashMap<>();
         originalScmInfo.put( ArtifactUtils.versionlessKey( project.getGroupId(), project.getArtifactId() ),
                              project.getScm() );
         config.setOriginalScmInfo( originalScmInfo );

--
To stop receiving notification emails like this one, please contact
['"[hidden email]" <[hidden email]>'].