On Fri, 23 Sept 2022 at 16:02, Alex Herbert <alex.d.herb...@gmail.com> wrote:
> > > I wonder if we can set up a Jenkins build to use the current CP snapshot > for a project. The mvn:versions command can change the project parent. > However this does not work for RNG: > > mvn versions:update-parent -DallowSnapshots=true > > This only updates to 54, not 55-SNAPHSOT. I presumed the snapshots for CP > are not deployed anywhere. However they do seem to be in the correct > location with a 55-SNAPSHOT recently deployed there [1]. Running with the > -X flag shows that the apache snapshots repo is being used for remote > artifacts. So something is not working with this command. If it can be made > to work then the Jenkins CI build can be configured using a pre-build step > to execute the shell command. > This seems to be a long standing bug in mvn:versions. I found a bug report from 2017 with the same use case: a project wishes to update the parent to the latest snapshot deployed to the snapshots repo (see [1]). Without a simple mvn command to resolve the latest CP I do not see how this can be easily maintained. A one line program would be required to inject the latest version into the POM based on incrementing the current version number by 1 and adding the SNAPSHOT suffix. Alex [1] https://github.com/mojohaus/versions-maven-plugin/issues/233