开发者

Running Maven Goals in CLI

I have a maven pom.xml file with multiple instances of a same goal defined (inside <executio开发者_Go百科n> with different <id>s).

I'm wondering how I can run a specific goal via maven command line. I've tried mvn --help, but I couldn't find an entry regarding this.


Answering my own question is always fun, especially the answer is "no, you can't do it."

After many Google searches, I've encountered the following article:

http://docs.codehaus.org/display/MAVENUSER/Default+Plugin+Execution+IDs

There is no way to separate configurations for command line executions of different goals in the same plugin.
Currently, the main plugin configuration section can be used to define settings to be used when executing a plugin from the command line. Unfortunately, these settings are applied to all executions of the plugin.


Having read your own answer, I'm not sure I understood the question :) But it sounds like this previous question and answer.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜