Skip to content

Commit fa46ab8

Browse files
committed
Add properties to featureFinishDevMergeMessage - closes #247
1 parent 434f9be commit fa46ab8

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/main/java/com/amashchenko/maven/plugin/gitflow/GitFlowFeatureFinishMojo.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,8 @@ public void execute() throws MojoExecutionException, MojoFailureException {
162162

163163
final String keptFeatureVersion = featureVersion;
164164

165+
final String version = keptFeatureVersion.replaceFirst("-" + featName, "");
165166
if (keptFeatureVersion.contains("-" + featName)) {
166-
final String version = keptFeatureVersion.replaceFirst("-" + featName, "");
167-
168167
// mvn versions:set -DnewVersion=... -DgenerateBackupPoms=false
169168
mvnSetVersions(version);
170169

@@ -184,8 +183,11 @@ public void execute() throws MojoExecutionException, MojoFailureException {
184183
gitMergeSquash(featureBranchName);
185184
gitCommit(featureBranchName);
186185
} else {
186+
Map<String, String> properties = new HashMap<String, String>();
187+
properties.put("version", version);
188+
properties.put("featureName", featName);
187189
// git merge --no-ff feature/...
188-
gitMergeNoff(featureBranchName, commitMessages.getFeatureFinishDevMergeMessage(), null);
190+
gitMergeNoff(featureBranchName, commitMessages.getFeatureFinishDevMergeMessage(), properties);
189191
}
190192

191193
// maven goals after merge

0 commit comments

Comments
 (0)