netbeans运行错误:无法执行目标org.codehaus.mojo:exec-maven-plugin:1.2.1

时间:2015-10-01 21:24:36

标签: java maven netbeans mojo

我对net-beans 8.0.2很新,想要运行java Artificog.com示例,但运行后会出现以下错误:

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project MachineLearning: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

这是pom.xml:

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>com.artificog</groupId>
    <artifactId>MachineLearning</artifactId>
    <version>1.0-SNAPSHOT</version>
    <packaging>jar</packaging>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <maven.compiler.source>1.7</maven.compiler.source>
        <maven.compiler.target>1.7</maven.compiler.target>
    </properties>
  <dependencies>
      <dependency>
    <groupId>org.apache.commons</groupId>
    <artifactId>commons-math</artifactId>
    <version>2.2</version>
    </dependency>
    <dependency>
    <groupId>org.apache.commons</groupId>
    <artifactId>commons-io</artifactId>
    <version>1.3.2</version>
</dependency>
  </dependencies>

</project>
我需要安装一些东西吗? 任何帮助表示感谢。

-Thanks

1 个答案:

答案 0 :(得分:1)

只要因任何原因无法运行,就会显示该错误消息。它之前是更具体的错误消息。因此,有关更多信息,请向上滚动。

很可能是构建错误,因此在编辑器窗口的右侧找到项目选项卡中有红色感叹号的每个源文件的红线,并修复这些行。