我可以让一个maven配置文件激活另一个吗? [英] Can I make one maven profile activate another?
本文介绍了我可以让一个maven配置文件激活另一个吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有2个maven2配置文件,selenium和jspc。现在对于seleniumid喜欢隐式激活jspc,这样我就不必从命令行编写mvn -Pselenium,jspc了。这可能吗?
I have 2 maven2 profiles, selenium and jspc. Now for "selenium" id'd like to have an implicit activation of "jspc", so that I don't have to write mvn -Pselenium,jspc from the command line. Is this possible ?
推荐答案
你不能链接配置文件激活( maven reference )但您可以通过同一属性激活它们:
You can't "chain" profile activations (maven reference) but you can activate them both through the same property:
<activation>
<property>
<name>profile.selenium</name>
</property>
</activation>
并且运行 mvn -Dprofile.selenium
这篇关于我可以让一个maven配置文件激活另一个吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文