Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在 Netbeans 下有一个 Maven 项目,它需要非默认配置,因为它是特定于平台的。如果用户不选择配置,我将无法知道要为哪个平台构建。我不能使用配置文件激活器,因为有时我们在 Linux 机器下构建 Windows 二进制文件。
如果使用了描述性错误消息,有没有办法禁用<default config>或失败构建,或者告诉 Netbeans 当有人构建<default config>它时应该真正构建配置windows-x86?
<default config>
windows-x86
默认配置只是意味着没有激活配置文件。因此,您的构建必须能够确定没有激活配置文件(通过任何方式,缺少属性,缺少插件配置)。maven enforcer 插件也许可以做到。netbeans 没有办法做这样的事情,你必须想出一个 maven 解决方案。