Configuring the MAVEN environment variable cmd console tip: MVN is not an internal or external command, or a program or batch file that can be run
First MAVEN environment variable:
Variable name: maven_home
Variable Value: E:\apache-maven-3.2.3
Variable name: Path
Variable value:;%maven_home%\bin
CMD console check to see if MAVEN is configured successfully
1: View MAVEN Installation path: Echo%maven_home%
2: View maven version: Mvn-version
Console tip: MVN is not an internal or external command, or a program or batch file that can be run
Workaround: Add in Path:%SYSTEMROOT%\SYSTEM32;%SYSTEMROOT%;%SYSTEMROOT%\SYSTEM32\WBEM;
Restart the CMD console to print the MAVEN version normally
I path:c:\windows\system32; C:\Windows; C:\Windows\System32\Wbem; c:\windows\system32\windowspowershell\v1.0\;%systemroot\system32;%systemroot%;
%systemroot%\system32\wbem;d:\program files\tortoisesvn\bin;%java_home%\bin;%java_home%\jre\bin;%maven_home%\ Bin
These are the more popular solutions online:
I add one more here, is the problem of illegal characters, if the path exists illegal characters do not
Before my path was D:\apache-maven-3.3.9\apache-maven-3.3.9.
Then I changed it to: D:\java\apache-maven-3.3.9.