versions-maven-plugin

Remove -SNAPSHOT from project version in pom

夙愿已清 提交于 2019-11-29 11:33:09
问题 I have a pom with the following GAV <groupId>com.company.services</groupId> <artifactId>test-branch-2</artifactId> <version>1.0.21-SNAPSHOT</version> I want to remove -SNAPSHOT from this using maven in batch mode, so I can do it with Jenkins and not have to specify anything manually. I've looked at the documentation for version:set but all the options offer me an interactive prompt and ask me to type a name for the version. I would prefer the versions plugin, not the release plugin. 回答1:

How can I update a property in a Maven POM?

时光毁灭记忆、已成空白 提交于 2019-11-28 21:12:46
I have two top-level Maven projects, backend and frontend , that advance versions at their own individual pace. Since each has multiple modules, I define my dependency versions in dependencyManagement sections in the parent/aggregate POMs and use a property for the version number. I want to cleanly update the property with the version number on frontend , preferably arbitrarily, but I can live with requiring a live upstream version to match. I've tried using versions:update-property , but that goal seems to be completely non-functional; regardless of whether there's actually a matching