-
Notifications
You must be signed in to change notification settings - Fork 114
Add options to skip Maven goals from command line #360
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
Comments
This should be relatively easy to implement. Something similar to https://github.com/spring-projects/spring-boot/blob/7377d85096ed943a06341d94e43a1208238850b5/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/StopMojo.java#L67-L68 |
Yes, exactly. Or as here ;): I missed that there is a skip in ValidateMojo ("spring-javaformat.skip). A bit unfortunate that is using a common property name. I would have preferred to use Perhaps, adding:
and deprecating:
The "skip all" could be placed directly in FormatMojo or? |
That was fast. Thanks @philwebb |
@philwebb Are there any tests for this? I can't seem to get it work unless I'm making a silly mistake. |
MRE: test.zip
|
@lfvjimisola It's a mismatch between the code and the readme. |
We would like to default to always applying formatting rules and then validating, i.e.
However, in our pipelines we then need to skip the apply goal to make sure that the code is actually correctly validated.
We would like to avoid using profiles and just add command line parameter similar to
-Dmaven.test.skip
, e.g.-Dspring-javaformat.apply.skip
-Dspring-javaformat.validate.skip
I've checked issues and code and could not see that it has been brought up or is implemented.
The text was updated successfully, but these errors were encountered: