문제

maven appears to have grown a --builder option:

$ mvn --help
usage: mvn [options] [<goal(s)>] [<phase(s)>]
[...]
Options:
  -b,--builder <arg>                     The id of the build strategy to
                                         use.

I don't find any documentation on it, anyone has an idea about what that is (before I RTFC)?

I'm using version 3.2.1, but I'm not sure when that appeared.

도움이 되었습니까?

해결책

From the Maven 3.2.1 release notes:

There is a new Builder interface which classes can implement to encapsulate a strategy for building projects. The existing strategies for building Maven serially and in parallel are now Builder implementations. It’s now possible for others to implement additional strategies for building projects. This is a provisional interface and may change in the near future but will stabilize by Maven 4.0.0.

The new Builder interface abstracts over different ways to schedule the building of a project, and is intended to allow new, potentially faster, strategies (Making Maven builds incredibly fast - "our new smart scheduling for Maven consists of a new parallelization model that is more aggressive, and optimized prioritization of project builds based on recording their execution times and persisting them for subsequent analysis.").

다른 팁

This is a constant problem with the maven crowd. It is nigh impossible to get a straight answer out of anyone. You would expect the command to be able to list the available builder identifiers, but nope. Or find a list of them in the documentation. Again nope. If a colleague hadn't pointed me towards the --builder=smart option, I would not have any readily available means to find out about it. That is pretty useless from a user's point of view.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top