Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New CLI for Maven. Goals are reusability, extensibility and easier embeddability (a la mvnd). If you build this branch, you will end up with Maven distro that uses "new"
maven-cli:org.apache.maven.cling.MavenCling
class as entry point instead of "old"maven-embedder:org.apache.maven.cli.MavenCli
.First step is to make "pretty much equivalent" capable CLI as compared to "old", with some exceptions:
-llr
present ONLY to make Maven fail are gone (now Arg parser will fail).Current state of affairs is messy, MavenCli mixes everything it can, contains interleaved logic for bootstrapping, arg parsing, default logic and executing Maven. First goal is to clean this up.
Commons CLI are also hidden in this PR, so is ClassWorlds. This basically opens up way to have "alternative" CLI arguments parsers as well.
Note: naming, as always is off. I just could not come up with better names, so "invoker" and "request" are used, but they are too generic, and they clash with existing Maven Invoker. Have to say, that this work could replace Maven Invoker on longer run with some much simpler and cleaner solution.
Currently the "local" (CLI) flow is this:
But the point is if you "come up" somehow with a Request instance, one can also do just:
Local parser:
Local invoker:
There are some experiments ongoing as well, like
ForkedInvoker
is, but alsoMavenTool
.