I have a few jobs in Jenkins - Jobs A,B and C.
A - is the version file. In the pom.xml there are versions for all the files.
B & C - other projects. In jenkins they are set up as a dependency for A. So after A is built B and C will be built.
**A set up**
<version>2023Sep.0<version>
<properties>
<B>1.1.0</B>
<c>1.2.0</C>
</properties>
**B and C set up**
<version>2023Sep.0</version>
All the projects have a pom.xml file. Now I need to update files. First i want to update project A . The version has change for 'A' and the version for 'B' has changed.
**'A' set up**
<version>2023Oct.0<version>
<properties>
<B>1.2.0</B>
<c>1.2.0</C>
</properties>
Since 'B' was changed 'B's version in its pom.xml needs to change. It needs to become
<version>2023Oct.0</version>
Is there a way to do this through Jenkins. These are freestyle jobs its not a pipeline. I could do it through code but I was hoping there would be an easier way through Jenkins.
Can this happen??
Optional
Here would be the perfect way for this to work.
- project A pom file is updated and Jenkins job is enabled.
- other projects pom.xml files are updated
- PR are opened to update those pom files
- once PR has enough approvals Jenkins automatically enables jobs for those projects and builds them.