From e48f02e0f5a937581e1b3ce2e7b0eaa2103042a8 Mon Sep 17 00:00:00 2001 From: msavitskiy Date: Fri, 21 Oct 2016 12:18:47 +0300 Subject: [PATCH] added the ability to set version in non interactive mode --- .../plugin/gitflow/GitFlowReleaseStartMojo.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/main/java/com/amashchenko/maven/plugin/gitflow/GitFlowReleaseStartMojo.java b/src/main/java/com/amashchenko/maven/plugin/gitflow/GitFlowReleaseStartMojo.java index 13603434..67a59bf9 100644 --- a/src/main/java/com/amashchenko/maven/plugin/gitflow/GitFlowReleaseStartMojo.java +++ b/src/main/java/com/amashchenko/maven/plugin/gitflow/GitFlowReleaseStartMojo.java @@ -49,6 +49,17 @@ public class GitFlowReleaseStartMojo extends AbstractGitFlowMojo { @Parameter(property = "sameBranchName", defaultValue = "false") private boolean sameBranchName = false; + /** + * Release version. + *
+ * + * Note: Work only in non interactive mode. + * + * @since 1.3.1 + */ + @Parameter(property = "releaseVersion", defaultValue = "") + private String releaseVersion = ""; + /** {@inheritDoc} */ @Override public void execute() throws MojoExecutionException, MojoFailureException { @@ -114,6 +125,8 @@ public void execute() throws MojoExecutionException, MojoFailureException { } catch (PrompterException e) { getLog().error(e); } + } else { + version = releaseVersion; } if (StringUtils.isBlank(version)) {