提示的错误信息如下: 如下图: 上面的提示已经比较清楚了。 你没有在你的环境变量中设置 JAVA_HOME 需要按照上面的设置一个环境变量。 如果你使用的是 IEDA 的话,你需要重启的 IDEA 环境。 如果你使用的是命令行工具的话,你也需要退出后重启。 然后再次进行编译,应该就能解决上面的问题了。[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.9.1:jar (attach-javadocs) on project codebank: MavenReportException: Error while creating archive: Unable to find javadoc command: The environment variable JAVA_HOME is not correctly set. -> [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
问题和解决