Skip to content

Commit

Permalink
Do not add SNAPSHOT suffix if it is already present in version-bump mojo
Browse files Browse the repository at this point in the history
  • Loading branch information
laeubi committed Aug 31, 2024
1 parent 9375c4b commit 8372b8d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public void buildEnded(MavenSession session) {
.orElseGet(() -> Versions.incrementVersion(currentVersion,
VersionBumpMojo.getIncrement(session, project, projectHelper)));
boolean isSnapshot = currentVersion.endsWith(TychoConstants.SUFFIX_SNAPSHOT);
if (isSnapshot) {
if (isSnapshot && !newVersion.endsWith(TychoConstants.SUFFIX_SNAPSHOT)) {
newVersion += TychoConstants.SUFFIX_SNAPSHOT;
}
logger.info(project.getId() + " requires a version bump from " + currentVersion + " => "
Expand Down

0 comments on commit 8372b8d

Please sign in to comment.