Mac OS上的mvn clean命令抛出错误

时间:2019-11-21 22:06:35

标签: maven maven-plugin osx-mavericks

我正在尝试删除由门挡创建的文档,并且由于“多根文档”而出错,请参阅以下链接以获取更多信息

https://github.com/doorstop-dev/doorstop/issues/293

解决方案是运行“ mvn clean”命令,但是“ mvn clean”命令出现以下错误。关于此的任何可能的解决方案。

(base) MANOJs-MacBook-Air:~ manojdeshpande$ mvn clean
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  0.090 s
[INFO] Finished at: 2019-11-21T23:01:40+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] The goal you specified requires a project to execute but there is no POM in this directory (/Users/manojdeshpande). Please verify you invoked Maven from the correct directory. -> [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/MissingProjectException

1 个答案:

答案 0 :(得分:1)

错误消息非常清楚:

  

您指定的目标需要一个项目来执行,但是没有   此目录中的POM(/ Users / manojdeshpande)。请验证你   从正确的目录调用了Maven

问题是Maven在运行maven clean命令的地方找不到pom文件(pom.xml是maven项目配置文件),因此即使您指定了Maven,也不可能知道该怎么做干净的目标。

也许您的pom文件位于 / Users / manojdeshpande 之外的其他位置?

相关问题