【发布时间】:2015-03-26 10:41:03
【问题描述】:
因此我有一个 Maven RPM 插件映射:
<mapping>
<directory>/etc/myconfig</directory>
<configuration>true</configuration>
<sources>
<source>
<location>${project.build.directory}</location>
<includes>
<include>*.conf</include>
</includes>
</source>
</sources>
</mapping>
但是,根据打包过程,可能有零个 .conf 文件要放入 /etc。发生这种情况时,RPM 插件会说:
[ERROR] Failed to execute goal org.codehaus.mojo:rpm-maven-plugin:2.1.2:rpm (default) on project clients:
Unable to copy files for packaging: You must set at least one file. -> [Help 1]
有没有什么方法可以让映射部分包含零文件?
【问题讨论】: