【问题标题】:Ninja framework Install Error with MavenNinja 框架使用 Maven 安装错误
【发布时间】:2014-07-07 18:44:15
【问题描述】:

我正在尝试在here 学习构建 RESTful Web 服务的 Ninja 框架

在新创建的 maven 项目文件夹中运行“mvn clean install”时出现以下错误:

[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.610 s
[INFO] Finished at: 2014-05-19T11:39:50-07:00
[INFO] Final Memory: 11M/81M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project ninja: Fatal error compiling: invalid target release: 1.7 -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

如果这很重要,我正在使用 Java 8 的 Mac Mavericks。谢谢

【问题讨论】:

  • 为什么是男人?你为什么要尝试通过 ninja 框架来学习 restfull webservices?春天或球衣还不够?

标签: java maven ninjaframework


【解决方案1】:

好吧,这听起来可能很傻,但我通过将 JAVA_HOME 添加到我的 Mac 上的路径来解决问题,否则,maven 在我的计算机上仍然使用 Java 1.6(我已经安装了 Java 1.8)。

export JAVA_HOME=$(/usr/libexec/java_home)

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-10-13
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-10-21
    相关资源
    最近更新 更多