mvn clean package -Dmaven.test.skip=true 报错:[ERROR] Unknown lifecycle phase “.test.skip=true“.

简介: mvn clean package -Dmaven.test.skip=true 报错:[ERROR] Unknown lifecycle phase “.test.skip=true“.

错误


PowerShell 运行 mvn命令不成功



[ERROR] Unknown lifecycle phase ".test.skip=true". 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]
[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/LifecyclePhaseNotFoundException


元婴


而 PowerShell 窗口下,执行带参数的需要’单引号’包起来才可以


解决


方法一


命令改为:


mvn clean install package '-Dmaven.test.skip=true'


方法二


不要使用PowerShell命令行模式,使用 cmd 进入命令行执行:


mvn clean install package -Dmaven.test.skip=true
相关文章
|
jenkins 持续交付
问题记录:jenkins构建时报错The goal you specified requires a project to execute but there is no POM in...
问题记录:jenkins构建时报错The goal you specified requires a project to execute but there is no POM in...
1713 0
问题记录:jenkins构建时报错The goal you specified requires a project to execute but there is no POM in...
|
资源调度 JavaScript Windows
'vue-cli-service' 不是内部或外部命令,也不是可运行的程序问题解决
【5月更文挑战第7天】'vue-cli-service' 不是内部或外部命令,也不是可运行的程序问题解决
21341 3
|
Java Linux 开发者
撸个反向代理工具,搞一搞JRebel
前言 本地反向代理 服务器反向代理【个人推荐】 IDEA安装JRebel并激活 服务器安装JRebel并激活
|
Java Maven Spring
类文件具有错误的版本 61.0, 应为 52.0
类文件具有错误的版本 61.0, 应为 52.0
5101 0
|
7月前
|
存储 缓存 负载均衡
Gateway 网关坑我! 被这个404 问题折腾了一年?
小富分享了一个困扰团队一年多的 SpringCloud Gateway 路由 404 问题。通过日志追踪和源码分析,发现是网关在 Nacos 配置更新后未能正确清理旧的路由权重缓存,导致负载均衡时仍使用已删除的路由数据。最终通过监听路由刷新事件并手动更新缓存,成功解决了问题。
1151 125
Gateway 网关坑我! 被这个404 问题折腾了一年?
|
JavaScript 前端开发 算法
【Node.js 版本过高】运行前端时,遇到错误 `Error: error:0308010C:digital envelope routines::unsupported`
【Node.js 版本过高】运行前端时,遇到错误 `Error: error:0308010C:digital envelope routines::unsupported`
9457 0
|
前端开发 Java Apache
Springboot整合shiro,带你学会shiro,入门级别教程,由浅入深,完整代码案例,各位项目想加这个模块的人也可以看这个,又或者不会mybatis-plus的也可以看这个
本文详细讲解了如何整合Apache Shiro与Spring Boot项目,包括数据库准备、项目配置、实体类、Mapper、Service、Controller的创建和配置,以及Shiro的配置和使用。
3431 2
Springboot整合shiro,带你学会shiro,入门级别教程,由浅入深,完整代码案例,各位项目想加这个模块的人也可以看这个,又或者不会mybatis-plus的也可以看这个
|
缓存 IDE Java
maven install报错原因揭秘:‘parent.relativePath‘指向错误的本地POM文件
在使用Maven构建项目时,遇到&#39;parent.relativePath&#39;错误通常是由于父项目POM路径设置错误、版本不一致或内容不匹配导致的。解决方法包括:校正父项目POM的相对路径、确保版本一致、保持POM文件内容同步,并排查其他潜在问题,如子模块命名冲突和Maven缓存问题。通过这些步骤可解决该错误,避免项目构建失败。
maven install报错原因揭秘:‘parent.relativePath‘指向错误的本地POM文件
|
数据采集 数据管理 大数据
推荐 | AllData开源数据中台技术分享
AllData数据中台架构师团队全面解析开源项目[alldata](https://github.com/alldatacenter/alldata),涵盖功能设计、架构分析及源码解读。团队分享了项目总结、发展规划,推荐关注公众号“大数据商业驱动引擎”以获取更多信息。他们讨论了数据治理、调度引擎、商业化探索及未来规划,涉及元数据管理、数据安全、Airflow调度引擎等。此外,还介绍了数据平台功能,如用户管理、权限控制,并提到了商业化版本的源码支持。鼓励用户参与社区交流,共同推动项目发展。
推荐 | AllData开源数据中台技术分享
|
Java Docker 容器
SpringBoot项目集成XXL-job
SpringBoot项目集成XXL-job
1824 1

热门文章

最新文章

下一篇
开通oss服务