简体   繁体   English

在Eclipse项目上安装时的Maven错误

[英]Maven errors when install on an Eclipse project

I'm trying to install maven on four projects. 我正在尝试在四个项目上安装Maven。 Let me explain the context : 让我解释一下上下文:

I have a project (not mine), and I'm trying to run it but I have errors in the code and it's obviously maven errors. 我有一个项目(不是我的项目),并且正在尝试运行它,但是代码中有错误,而且显然是行家错误。 I have configured the Maven Environnement with this tuto : http://www.tutorialspoint.com/maven/maven_environment_setup.htm and it seems to work. 我已经使用以下Tuto配置了Maven环境: http ://www.tutorialspoint.com/maven/maven_environment_setup.htm,它似乎可以工作。

About the project, the entire project is dividing in four projects. 关于该项目,整个项目分为四个项目。 I own only this four project, maybe they don't give me all the sources of the project (stupid) but why not. 我只拥有这四个项目,也许他们没有给我所有项目的资源(愚蠢的),但是为什么不呢。

So I'm trying to install maven in each projects and I have some errors, could you tell me what it means please ? 所以我试图在每个项目中安装Maven,但出现一些错误,请告诉我这是什么意思? And what should I do to resolve it ? 我应该怎么做才能解决呢?

在此处输入图片说明

Text version : 文字版本:

C:\Users\Lison\workspace\Persyst_1.4>mvn clean install -U
[INFO] Scanning for projects...
Downloading: 

https://repo.maven.apache.org/maven2/eu/akka/AkkaToulouseSuperPom/1
.0/AkkaToulouseSuperPom-1.0.pom
[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[FATAL] Non-resolvable parent POM for fr.inra.grignon:persyst:1.0-SNAPSHOT: Coul
d not find artifact eu.akka:AkkaToulouseSuperPom:pom:1.0 in central (https://rep
o.maven.apache.org/maven2) and 'parent.relativePath' points at wrong local POM @
 line 6, column 10
 @
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR]   The project fr.inra.grignon:persyst:1.0-SNAPSHOT (C:\Users\Lison\works
pace\Persyst_1.4\pom.xml) has 1 error
[ERROR]     Non-resolvable parent POM for fr.inra.grignon:persyst:1.0-SNAPSHOT:
Could not find artifact eu.akka:AkkaToulouseSuperPom:pom:1.0 in central (https:/
/repo.maven.apache.org/maven2) and 'parent.relativePath' points at wrong local P
OM @ line 6, column 10 -> [Help 2]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
ch.
[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 rea
d the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildin
gException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableMo
delException

**EDIT : ** **编辑:**

Project 1
    >src
    >compile
    >pom.xml
Project 2
    >src
    >pom.xml
Project 3
    >src
    >pom.xml
Project 4
    >src
    >pom.xml

It is showing 它显示

Non-resolvable parent POM for fr.inra.grignon:persyst:1.0-snapshot fr.inra.grignon:persyst:1.0快照的不可解析的父POM

it means this indicates that maven did search locally for the parent pom, but found that it was not the correct pom or missing. 这意味着这表明maven确实在本地搜索了父pom,但是发现它不是正确的pom或缺少。 if the project is multimodule it should have parent project. 如果项目是多模块,则应具有父项目。

Reference For multimodule Project you may check this link: 参考对于多模块项目,您可以检查以下链接:

https://maven.apache.org/guides/mini/guide-multiple-modules.html https://maven.apache.org/guides/mini/guide-multiple-modules.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM