Maven程序集插件未在解包的dependencySet上应用fileMode [英] Maven assembly plugin not applying fileMode on unpacked dependencySet
问题描述
整个下午,我一直在用头撞墙.我需要创建一对程序集(zip
和tgz
),并需要为存档中包含的Shell脚本设置正确的可执行权限.
I have been banging my head against the wall all afternoon with this one. I need to create a pair of assemblies (zip
and tgz
) and need to set the correct executable permissions for shell scripts included in the archive.
我所做的似乎没有什么区别,fileMode
设置似乎无效.这是我的程序集描述符中的一个片段:
It doesn't seem to make any difference what I do, the fileMode
settings seem to have no effect. Here is a snippet from my assembly descriptor:
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<useStrictFiltering>true</useStrictFiltering>
<outputDirectory></outputDirectory>
<unpack>true</unpack>
<fileMode>0755</fileMode>
<unpackOptions>
<lineEnding>keep</lineEnding>
<includes>
<include>**/*.sh</include>
</includes>
</unpackOptions>
<includes>
<include>com.example:my-artifact:jar</include>
</includes>
</dependencySet>
松开后,我看不到我的期望,例如
After untarring I do not see what I expect, e.g.
tar pxvf target/my-package-1.0.0-SNAPSHOT.tgz
我尝试使用p和不使用p,但是我仍然想念可执行权限:
I've tried with and without the p, but I still miss executable perms:
-rw-r--r-- 1 MWard staff 1468 3 Sep 09:58 a_script.sh
关于我可能要去哪里的任何想法?谢谢!
Any ideas as to where I may be going wrong? Thanks!
推荐答案
这是一个错误: https://issues.apache.org/jira/browse/MASSEMBLY-829
解决了maven-assembly-plugin 3.0.0-SNAPSHOT
Solved in maven-assembly-plugin 3.0.0-SNAPSHOT
这篇关于Maven程序集插件未在解包的dependencySet上应用fileMode的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!