Maven - 报错篇
发布日期:2021-06-30 23:47:17 浏览次数:2 分类:技术文章

本文共 1245 字,大约阅读时间需要 4 分钟。

No goals have been specified for this build. You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id>[:<plugin-version>]:<goal>. Available lifecycle phases are: validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy, pre-clean, clean, post-clean, pre-site, site, post-site, site-deploy. -> [Help 1]  

报错翻译:这个Maven项目不知道要执行哪个命令。

解决方案:

  1. pom.xml文件 <build> 标签后面加上 <defaultGoal>compile</defaultGoal> 即可。
  2. 如图

Failed to execute goal org.apache.maven.plugins:maven-gpg-plugin:1.6:sign (sign-artifacts) on project dubbo-spring-boot-starter: Unable to execute gpg command: Error while executing process. Cannot run program "gpg.exe": CreateProcess error=2, 系统找不到指定的文件。 -> [Help 1]

报错翻译:使用的版本是maven3.X,其执行maven-ant-plugin的行为和maven2.x有一定的不同,需要引入pluginManagement。

解决方案:

...
...

转载地址:https://lux-sun.blog.csdn.net/article/details/84310068 如侵犯您的版权,请留言回复原文章的地址,我们会给您删除此文章,给您带来不便请您谅解!

上一篇:C/C++ - 数组篇
下一篇:Spring - AOP之传统手动代理

发表评论

最新留言

关注你微信了!
[***.104.42.241]2024年05月04日 03时30分29秒