我想为Alfresco开发一个票务系统附加组件,
我是Alfresco的新手,所以我有一些麻烦
开始我已经下载了 maven 并设置了路径变量也适用于 java 和 javac
现在我用命令安装了一个简单的 Maven 项目
mvn archetype:generate -Dfilter=org.alfresco:
一切都安装得很好。然后我尝试使用命令
mvn install
但是在那里我得到错误:
[INFO] Compiling 3 source files to E:HTLAlfrescomaven_projectsquick-
start-projecttargetclasses
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.473 s
[INFO] Finished at: 2018-04-17T15:58:33+02:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.5:compile (default-compile) on project quick-start-project: Compilation failure
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[ERROR]
[ERROR] -> [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/MojoFailureException
我还尝试在我的文件夹中运行 run.bat 文件,但它在一段时间后因错误而关闭!
谁能帮助我,并有一些开始为Alfresco开发的技巧?
请尝试这个
在 Eclipse IDE 上,进入 Window> Preferences> Java>已安装的 JRE>并检查已安装的 JRE。
你应该有一个带有JDK的条目。选择执行环境,如下所示。 单击"确定">
然后右键单击您的项目 -> Maven -> 更新项目
,然后选择 JDK
参考此社区链接可能会对您有所帮助