# Version Management
This document is about Version Management of Sermant.
Sermant manages versions via versions-maven-plugin (opens new window). Common commands are as follows:
Update current version to
${version}:mvn versions:set -DnewVersion=${version}This command keeps the original
pomfile backup by default.Rollback the version:
mvn versions:revertCommit the new version updated (delete the original
pomfile backup):mvn versions:commitUpdate current version to
${version}and commit:mvn versions:set -DnewVersion=${version} -DgenerateBackupPoms=falseThis command will not back up the original
pomfile, be careful not to write the wrong version number when executing it.
After executing the above update commands, only the modules with the same version as the top-level module in the project will be modified. If you need to update a module separately, you can specify it with -pl, for example:
mvn versions:set -DnewVersion=${version} -DgenerateBackupPoms=false -pl ${module}
Where ${module} can be ${groupId}:${artifactId}. Or you can input relative path of the module. In the case of multiple modules, please use ','.
For more information on setting versions with the versions:set command, refer to Versions Maven Plugin versions:set (opens new window).
Refer to Versions Maven Plugin Introduction (opens new window) for more versions-maven-plugin commands.
