Maven要求检查ant jar是否完整

时间:2015-10-28 10:50:25

标签: maven ant clover

我遇到了maven和ant的问题。我将罐子从仓库中拉到我的电脑上,并将repo上所需的所有罐子和refs添加到pom文件中。当我尝试运行clover2:setup时出现错误

Downloading: http://remoteRepo/nexus/content/groups/xxxx/org/apache/ant/ant/1.8.4/ant-1.8.4.jar
1896K downloaded  (ant-1.8.4.jar)
[INFO] ---------------------------------------------------------------------    ---
[ERROR] FATAL ERROR
[INFO] ---------------------------------------------------------------------    ---
[INFO] The plugin descriptor for the plugin Plugin [org.apache.ant:ant] was not
found. Please verify that the plugin JAR     C:\Users\xxxx\Documents\localrepo\or
g\apache\ant\ant\1.8.4\ant-1.8.4.jar is intact.
[INFO] ------------------------------------------------------------------------
[INFO] Trace
java.lang.IllegalStateException: The plugin descriptor for the plugin Plugin [or
g.apache.ant:ant] was not found. Please verify that the plugin JAR C:\Users\xxxx\Documents\localrepo\org\apache\ant\ant\1.8.4\ant-1.8.4.jar is intact.
    at org.apache.maven.plugin.DefaultPluginManager.addPlugin(DefaultPluginM
anager.java:360)
    at org.apache.maven.plugin.DefaultPluginManager.verifyVersionedPlugin(De
faultPluginManager.java:224)
    at org.apache.maven.plugin.DefaultPluginManager.verifyPlugin(DefaultPlug
inManager.java:184)
    at org.apache.maven.plugin.DefaultPluginManager.loadPluginDescriptor(Def
aultPluginManager.java:1642)
    at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(Defa
ultLifecycleExecutor.java:1540)
    at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor
(DefaultLifecycleExecutor.java:1787)
    at org.apache.maven.lifecycle.DefaultLifecycleExecutor.segmentTaskListBy
AggregationNeeds(DefaultLifecycleExecutor.java:462)
    at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
fecycleExecutor.java:175)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
    at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
0)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
    at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
    at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3 seconds
[INFO] Finished at: Wed Oct 28 05:37:02 CDT 2015
[INFO] Final Memory: 7M/122M
[INFO] ------------------------------------------------------------------------

我已经提取了jar文件并检查了Manifest.MF文件及它的pom,我的pom中的ref也是一样的。

一个罐子不被认为完好无损的原因是什么?

网址中的远程回购只是为了隐藏实际网址指向的位置,但留下来显示它的拉罐并且不是代理问题。我也多次清理当地的回购

1 个答案:

答案 0 :(得分:1)

org.apache.ant:ant不太可能是Maven插件。检查你的pom.xml是否有不正确的插件声明。