Skip to content
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

run custom goals #54

Closed
HonoluluHenk opened this issue Jun 30, 2017 · 6 comments
Closed

run custom goals #54

HonoluluHenk opened this issue Jun 30, 2017 · 6 comments

Comments

@HonoluluHenk
Copy link

We do have excessive enforcer (http://maven.apache.org/enforcer/maven-enforcer-plugin/) rules set up to prevent some errors (like allowSnapshots, but much more).
Also: integration tests do not run.

Our customers CI does not allow custom goals to be run, so we're basically stuck with mvn clean deploy and have to do our releases locally, then letting the CI build master.

Now what I'd like to do is (pseudo-code):
mvn -DskipTestProject=true gitflow:release-start clean verify mycoolgoal gitflow:release-finish
This command line actually does run but uses the SNAPSHOT version it started with, so enforcer does not see the release version and does not fail. Splitting this into two separate mvn commands works but is not very nice :(

What would be really cool is a configuration parameter that lets me set the goals during release:
Sample-command line:
mvn -DskipTestProject=true -DreleaseGoals=clean,verify,mycoolgoal gitflow:release
This might make skipTestProject obsolete since it could be replaced by -DreleaseGoals=
Also might make allowSnapshots obsolete since it could be replaced by using enforcer rule "requireReleaseDeps"

Implementing this might also solve #29 (mvn -DreleaseGoals clean,deploy gitflow:release-finish) and #13 (mvn -DreleaseGoals clean,install gitflow:release-finish)

@aleksandr-m
Copy link
Owner

@HonoluluHenk Take a look at this commit in the feature/additional_goals branch. Ideas and feedback are welcome.

@phuonghuynh
Copy link

@aleksandr-m how can i use this feature?

@aleksandr-m
Copy link
Owner

@phuonghuynh It isn't released yet. But you can checkout feature/additional_goals, install and test it.

@phuonghuynh
Copy link

@aleksandr-m I tested the branch, waiting this feature in next release.

@aleksandr-m
Copy link
Owner

Implemented in 9e57bb0.

@aleksandr-m
Copy link
Owner

@HonoluluHenk @phuonghuynh 1.8.0 is released. See Running custom Maven goals.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants