- idea 终端执行如下命令时
java
mvn clean install -Dmaven.skip.test=true
- 报:
java
Unknown lifecycle phase ".skip.test=true". You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or
<plugin-group-id>:<plugiprepare-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]
- 原因:命令没有被终端有效的识别到
- 解决方法:
1、打开 idea 设置
2、切换为:C:\Windows\system32\cmd.exe
3、或者也可以在默认终端(powershell.exe)运行命令的时候加上引号,如:
java
mvn clean install '-Dmaven.skip.test=true'