-
Notifications
You must be signed in to change notification settings - Fork 267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
${revision} not being updated #855
Comments
Regression after #799 |
Too bad we're after this hotfix release. |
Why do you use Do you also need a task to change pinned version to
|
We use Thus we also have this problem. The workaround seems to be adding |
This workaround also worked for me, thanks 🙏🏼 |
I'm looking into switch from normal versions to these CI friendly versions. I can use shell scripting to add the |
With 2.15.0, when I run Adding What am I missing? Fwiw, I'm using a multi-module project with a CI pipeline that is forcing the |
@CharlieReitzel see this scenario: #855 (comment) |
I don't think that the Before version 2.13.0, it did not interpolate properties at all. In versions 2.14.0 and 2.15.0 it made an incomplete attempt at doing it, but I'm now reverting that behaviour. |
Thanks for the quick responses on a closed ticket. @deckrider said:
That's where I got the idea to try @ajarmoniuk So, if I understand it right. If you use Should I submit a feature request to support updating the version for projects that use the |
Yes, of course you can request a new feature. By the way, what are you trying to achieve by trying to use set on CI-friendly versions? Edit: Unless your ${revision} properly is also defined in your POM, then you should have rather used the set-property goal. |
In our work environment, all projects use shared CI/CD pipeline code that forces a version update with every merge to Because I'm using a multi-module project, I'm using
Fwiw, I don't see any logical conflict or disconnect between using CI-friendly ( |
So, did you try using set-property instead? |
I can play with it, manually. But, as I said, my project has to work with a standard CI pipeline that forces I have no problem with that scheme, either. To my mind the "least surprise" implementation of |
Please do file a feature request. The set goal you described is supposed to update the version of the project with which it was invoked across the agregator, i.e. also update it where it's used as parent or dependency. So I understand the intention of the pipeline maintainer and the invocation of set should leave the project in a consistent state. If this does not occur then it's a bug, and might be caused by #799. Please notify the pipeline maintainer of that fact. However, the set goal in the pipeline would replace your property with a direct value, which is not what you want. Regarding one remark – by "CI-friendly versions" I understand versions where the property is defined outside of the reactor, typically in the pipeline, e.g. by using the -Drevision switch. So it would not make sense to define a property in the project, which is then redefined in the pipeline anyway, hence my surprise. So, unfortunately what you're looking for is not currently available with the set goal. |
This is a sample pom to illustrate the issue
`
4.0.0
`
mvn versions:set -DnewVersion=2.0
With plugin 2.13.0 it resolves all ${revision} to the new version.
With plugin 2.14.0 and 2.14.1 it does nothing.
The text was updated successfully, but these errors were encountered: