gpt4 book ai didi

maven-3 - 执行maven命令后出现错误 "The goal you specified requires a project to execute but there is no POM in this directory"

转载 作者:行者123 更新时间:2023-12-03 04:43:18 25 4
gpt4 key购买 nike

我在 C:\Users\AArmijos\Desktop\Factura Electronica\MIyT\componentes-1.0.4\sources\pom.xml 中有一个 pom.xml 和我执行了:

mvn install:install-file -DgroupId=es.mityc.jumbo.adsi -DartifactId=xmlsec-1.4.2-ADSI -Dversion=1.0 -Dpackaging=jar -Dfile=C:\Users\AArmijos\Desktop\Factura Electronica\MIyT\componentes-1.0.4\core\xmlsec-1.4.2-ADSI-1.0.jar

但是它返回了以下错误:

[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.310s
[INFO] Finished at: Thu May 02 16:48:29 COT 2013
[INFO] Final Memory: 2M/15M
[INFO] ------------------------------------------------------------------------
[ERROR] The goal you specified requires a project to execute but there is no POM
in this directory (C:\Users\AArmijos). Please verify you invoked Maven from the
correct directory. -> [Help 1]

有人能解释一下为什么失败吗?

最佳答案

此链接有帮助:https://stackoverflow.com/a/11199865/1307104

我通过为每个参数添加引号来编辑命令,如下所示:

mvn install:install-file "-DgroupId=org.mozilla" "-DartifactId=jss" "-Dversion=4.2.5" "-Dpackaging=jar" "-Dfile=C:\Users\AArmijos\workspace\componentes-1.0.4\deps\jss-4.2.5.jar"

成功了。

关于maven-3 - 执行maven命令后出现错误 "The goal you specified requires a project to execute but there is no POM in this directory",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16348459/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com