部署失败:未在POM中指定存储库元素

时间:2019-07-04 19:34:34

标签: java spring maven spring-mvc intellij-idea

我为Intellij Idea导入了一个Maven应用程序。配置Spring和Hibernate之后,我尝试构建它。但是,Maven向我返回了一个错误,该错误是:

[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 8.571 s
[INFO] Finished at: 2019-07-04T15:49:48-03:00
[INFO] Final Memory: 16M/211M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy (default-deploy) on project GECi: Deployment failed: repository element was not specified in the POM inside distributionManagement element or in -DaltDeploymentRepository=id::layout::url parameter -> [Help 1]
[ERROR] 

如果您能帮助我,我会很感激:D谢谢

1 个答案:

答案 0 :(得分:0)

调用mvn deploy表示您希望部署到Maven存储库。您需要在POM的<distributionManagement>元素中指定该存储库。