Search code examples
maventagsjenkinscvsmaven-release-plugin

Jenkins Tag After Maven Build


I have a multi-module-maven project.

The jenkins job pipe is like that in my case:

  1. Injecting environment variables for variable versioning
  2. Check out from cvs
  3. Edit Version.properties file of my project via shell (using the injected variables)
  4. Perform mvn release:update-version to update POM version(s) (using the injected variables)
  5. List item
  6. Perform mvn build
  7. Finally perform a CVS tagging (using the injected variables)

But now the changes of the POMs and the Version.properties are not updated in the tag. So my question is, which workspace is tagged in CVS. What do i have to do to include the version changes in my tag?


Thank you for the fast response!

I have added a cvs commit after step 6 (maven build):

cvs commit -m "blabla"

the result is that the changes are commited but in the tag still the preversion is there. because of that my question was which workspace jenkins is tagging.

  • Does he use the workspace of jenkins (i don't think so because the changes are not there)
  • Does he use the head of cvs (after the cvs commit the head contains the new versions so i don't think jenkins uses the head neither)
  • Does he use some cached workspace?

Solution

  • You are missing a CVS commit between step 6 and 7.