本文主要是介绍% invalid END header (bad central directory offset) 问题解决,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
初次执行 maven install 时报错:
invalid END header (bad central directory offset)
解决方法:
- 删除报错路径下的jar包,让maven重新下载即可.
原因:
文件模式/格式不匹配.
参考
https://stackoverflow.com/questions/20129885/throwing-error-executing-jar-file-after-executing-dos2unix-command-in-linux
https://access.redhat.com/solutions/1335343
报错详细:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile) on project EJOS: Compilation failure
[ERROR] Failure executing javac, but could not parse the error:
[ERROR] 错误: 读取/home/gaoyisheng/.m2/repository/junit/junit/4.11/junit-4.11.jar时出错; invalid CEN header (bad signature)
[ERROR] 1 个错误
[ERROR]
[ERROR]
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-c
2
[ERROR] Failed to parse plugin descriptor for org.apache.maven.plugins:maven-war-plugin:2.2 (/home/gaoyisheng/.m2/repository/org/apache/maven/plugins/maven-war-plugin/2.2/maven-war-plugin-2.2.jar): invalid END header (bad central directory offset) -> [Help 1]
org.apache.maven.plugin.PluginDescriptorParsingException: Failed to parse plugin descriptor for org.apache.maven.plugins:maven-war-plugin:2.2 (/home/gaoyisheng/.m2/repository/org/apache/maven/plugins/maven-war-plugin/2.2/maven-war-plugin-2.2.jar): invalid END header (bad central directory offset)at org.apache.maven.plugin.internal.DefaultMavenPluginManager.extractPluginDescriptor (DefaultMavenPluginManager.java:241)at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getPluginDescriptor (DefaultMavenPluginManager.java:186)at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getMojoDescriptor (DefaultMavenPluginManager.java:286)at org.apache.maven.plugin.DefaultBuildPluginManager.getMojoDescriptor (DefaultBuildPluginManager.java:241)at org.apache.maven
这篇关于% invalid END header (bad central directory offset) 问题解决的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!