Maven错误:无法执行目标org.codehaus.mojo:exec-maven-plugin:1.2.1:exec
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Maven错误:无法执行目标org.codehaus.mojo:exec-maven-plugin:1.2.1:exec相关的知识,希望对你有一定的参考价值。
我正在使用netbeans。我试图重新安装它,但它没有用。以下是运行mvn clean install -X时的堆栈跟踪:
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 1
at org.neuroph.util.NeurophArrayList.get(NeurophArrayList.java:376)
at org.neuroph.core.Layer.getNeuronAt(Layer.java:230)
at org.neuroph.util.ConnectionFactory.forwardConnect(ConnectionFactory.java:231)
at neuralNetwork.util.NeuralNetworkBuilder.customStandardNNet(NeuralNetworkBuilder.java:34)
at com.mycompany.redneuronal.redNeuronal.main(redNeuronal.java:25)
------------------------------------------------------------------------
BUILD FAILURE
------------------------------------------------------------------------
Total time: 1.157s
Finished at: Sun Mar 04 17:00:22 ART 2018
Final Memory: 5M/123M
------------------------------------------------------------------------
Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project perceptron: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project perceptron: Command execution failed.
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoExecutionException: Command execution failed.
at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:362)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more
Caused by: org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)
at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:377)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:160)
at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:610)
at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:352)
... 21 more
我还尝试重新安装maiven并删除我的本地存储库。如果你能帮助我,我将不胜感激。
通过在我的NetBeans项目上将exec-maven-plugin 1.2.1升级到1.6.0来解决此问题。
您可以通过以下方式执行此操作:
Project > Properties > Actions
在那里,选择运行proyect并将“org.codehaus.mojo:exec-maven-plugin:1.2.1:exec”替换为“org.codehaus.mojo:exec-maven-plugin:1.6.0:exec”。
以上是关于Maven错误:无法执行目标org.codehaus.mojo:exec-maven-plugin:1.2.1:exec的主要内容,如果未能解决你的问题,请参考以下文章
Maven 构建编译错误:无法在项目 Maven 上执行目标 org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-c
如何解决maven构建错误无法执行目标com.github.eirslett?
构建项目时出现错误,无法执行目标 org.apache.maven.plugins:maven-javadoc-plugin:2.10.4:jar (attach-javadocs)
Maven错误:无法执行目标org.codehaus.mojo:exec-maven-plugin:1.2.1:exec
无法在项目上执行目标 org.apache.maven.plugins:maven-compiler-plugin (default-compile):致命错误编译:未找到 tools.jar