Running commands from the Maven toolbar fails after upgrade
已回答
After upgrading to Build #IU-252.23892.409, built on August 1, 2025 running commands from Maven sidebar fails if VM argument is passed through “VM Options” setting (File | Settings | Build, Execution, Deployment | Build Tools | Maven | Runner). For example if -Xmx2g is set and clean command is executed, the error message is:
Unknown lifecycle phase "mx2g". 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: pre-clean, clean
Log file shows that this is the actual command:
cmd.exe /c "D:\bin\apache-maven-3.9.5\bin\mvn.cmd -Didea.version=2025.2 "-Dmaven.ext.class.path=C:\Program Files\JetBrains\IntelliJ IDEA 2024.1\plugins\maven\lib\maven-event-listener.jar" -Djansi.passthrough=true -Dstyle.color=always -Xmx2g -DskipTests=true -T 4 clean"
It seems that the problem is in escaping the quotes.
请先登录再写评论。
We are working on resolving this issue in the scope of https://youtrack.jetbrains.com/issue/IDEA-376845
The fix will be available in the upcoming version 2025.2.1 scheduled for release on August 26.
As a workaround until then, if you need to use custom VM options, you can install the previous version 2025.1.4.1 available here: https://www.jetbrains.com/idea/download/other.html
Thank you, Arina.