是否可以通過命令行的id來調用maven-exec-plugin(或任何其他插件)的執行?Maven-maven-exec-plugin多個執行配置
比方說,我的pom.xml文件看起來是這樣的:
<project>
[...]
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>foo</id>
<goals>
<goal>exec</goal>
</goals>
<phase></phase>
<configuration>
<executable>echo</executable>
<arguments>
<argument>foo</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>bar</id>
<goals>
<goal>exec</goal>
</goals>
<phase></phase>
<configuration>
<executable>echo</executable>
<arguments>
<argument>bar</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
[...]
</project>
現在是它可以調用
MVN高管:EXEC
增加了一些魔法運行執行「富」?
對於好奇存在利用可在這裏型材的替代解決方案: http://www.mail-archive.com/[email protected]/msg00151.html
我不能讓插件一起工作標籤中的。但它確實能夠將它放在標籤之外。錯誤是目標org.codehaus.mojo的「The parameters'executable':exec-maven-plugin:1.2.1:exec缺失或無效」 –
avanderw
2012-09-21 08:47:26
請注意,在上述「使用配置文件的替代解決方案」中,「'標籤丟失。 –
zb226
2015-01-23 07:09:08