问题描述
从某些程序集插件版本开始,maven构建会发出以下警告:
Starting from some assembly plugin version maven builds issue the following warning:
是否有推荐的现成解决方案?直接谷歌搜索给我带来了很多垃圾,没有任何实际帮助.重新检查Maven程序集插件帮助没有为我提供答案,也许其他人具有更好的搜索技能并可以提供帮助.
Is there any recommended ready-to-use solution for this? Direct googling provided me with lot of trash and no real help. Re-check of Maven assembly plugin help did not provide answer for me, maybe someone else has better search skill and can help.
更新
是的,这可能是由于类似Linux的outputDirectory
,但是我应该如何重写它以便移植?查看了程序集插件文档,但未找到任何可移植性指南.
Yes, this is probably because of Linux-like outputDirectory
but how should I rewrite this to be portable? Looked at assembly plugin documentation and not found any portability guide.
<fileSets>
<fileSet>
<directory>${basedir}/src/main/resources</directory>
<outputDirectory>/</outputDirectory>
</fileSet>
</fileSets>
推荐答案
有效的解决方案是指定空的outputDirectory
:
The working solution is to specify the empty outputDirectory
:
<fileSets>
<fileSet>
<directory>${basedir}/src/main/resources</directory>
<outputDirectory></outputDirectory>
</fileSet>
</fileSets>
这篇关于Maven程序集插件警告“程序集描述符包含文件系统根相对引用".的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!