Pergunta

I am having issues running mvn --version anywhere outside of C:\Program Files\Apache Software Foundation\apache-maven-3.2.1\bin. If I run mvn --version inside the apache-maven/bin folder I get the version number, however if I run it anywhere outside it says will not recognize mvn.

Am I missing something in my path variables?

My System Variables:

M2 = %M2_HOME%\bin
M2_HOME = C:\Program Files\Apache Software Foundation\apache-maven-3.2.1
JAVA_HOME = C:\Program Files\Java\jdk1.7.0_51

I appended

Path = ; %M2%

My User Variables:

M2 = %M2_HOME%\bin
M2_HOME = C:\Program Files\Apache Software Foundation\apache-maven-3.2.1
JAVA_HOME = C:\Program Files\Java\jdk1.7.0_51

Thanks

Foi útil?

Solução

You have to define variables before you use them. Change the order of the first two lines in your first example, and set PATH, not Path.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top