java – Maven程序集插件:无法使用以下命令检索数字文件属性:’/ bin / sh -c ls -1nlaR
发布时间:2020-05-28 08:20:43 所属栏目:Java 来源:互联网
导读:我在我的OSX 10.7.5上运行与Debian的并行,并且我已将目录与OSX中的 Java源链接到虚拟Debian机器(使用Parallels工具,将目录挂载到/ media / psf /). 编译工作正常,只有我遇到的问题是Maven Assembly插件:抱怨: Failed to retrieve numeric file attributes u
|
我在我的OSX 10.7.5上运行与Debian的并行,并且我已将目录与OSX中的 Java源链接到虚拟Debian机器(使用Parallels工具,将目录挂载到/ media / psf /). 编译工作正常,只有我遇到的问题是Maven Assembly插件:抱怨: Failed to retrieve numeric file attributes using: '/bin/sh -c ls -1nlaR 我搜索了以下问题:http://jira.codehaus.org/browse/MASSEMBLY-588 他们建议使用< directory> ${baseDir}< / directory>在jarlib.xml中.通过这个修改,代码编译,但是当使用jar tf file.jar检查内容时,它完全缺少所有已编译的源,只添加了maven库. 在本地文件系统上正常工作的文件是: <assembly>
<id>jar-with-dependencies</id>
<formats>
<format>jar</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>target/classes</directory>
<outputDirectory>/</outputDirectory>
</fileSet>
</fileSets>
<dependencySets>
<dependencySet>
<outputDirectory>/lib</outputDirectory>
<unpack>false</unpack>
<scope>runtime</scope>
</dependencySet>
</dependencySets>
</assembly>
有没有办法克服这个问题? 编辑: Apache Maven 2.2.1 (rdebian-4) Java version: 1.6.0_26 Java home: /usr/lib/jvm/java-6-sun-1.6.0.26/jre Default locale: en_US,platform encoding: UTF-8 OS name: "linux" version: "2.6.32-5-amd64" arch: "amd64" Family: "unix" 解决方法/ bin / sh -c ls -1nlaR {directory_structure / file}我通过重命名在directory_structure中有Apostrophe(‘)的文件夹来解决它. 创建此问题是因为maven程序集在执行命令/ bin / sh -c ls -1nlaR {directory_structure / file}时没有逃避撇号(‘). (编辑:安卓应用网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
