我刚刚下载了Maven 3.0.4。意外的maven目录
我的变量是:
M2_HOME C:\Program Files (x86)\apache-maven-3.0.4
JAVA_HOME C:\Program Files\Java\jdk1.6.0_35
和我的道路
C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files (x86)\Common Files\Roxio Shared\DLLShared\;C:\Program Files (x86)\Common Files\Roxio Shared\OEM\DLLShared\;C:\Program Files (x86)\Common Files\Roxio Shared\OEM\DLLShared\;C:\Program Files (x86)\Common Files\Roxio Shared\OEM\12.0\DLLShared\;C:\Program Files (x86)\Roxio\OEM\AudioCore\;%FRASCATI_HOME%/bin;%JAVA_HOME%\bin;%M2_HOME%\bin
我得到这个错误,当不上的maven目录:
C:\Users\rmescalera>mvn -version
"mvn" no se reconoce como un comando interno o externo,
programa o archivo por lotes ejecutable.
这等从行家目录:
ERROR: M2_HOME is set to an invalid directory. M2_HOME = "C:\Program Files (x86)\apache-maven-3.0.4\bin" Please set the M2_HOME variable in your environment to match the location of the Maven installation
点是在Maven webpage它说,设置%MAVEN_HOME%\在PATH斌但是当我下载并解压缩,这是结构我得到:
所以,很明显存在的Apache Maven的-3.0.4没有bin目录!
我试图复制只里面有什么
C:\Program Files (x86)\apache-maven-3.0.4\apache-maven\src
到一个新的C:/maven directory and setting the right variables
有什么不对?我得到的这个目录结构怎么了?我的变量应该指向哪里?
thx basiljames和@ kothvandir,我已经这么做了。我现在得到了正确的结构,但仍然得到相同的错误:无论从哪个目录调用mvn -version,M2_HOME都设置为无效目录。我试着直接转到C:\ maven以及以上所有内容! – eskalera
问题解决。我只需要删除我按照maven安装说明创建的用户变量。 Afeter下载并安装二进制压缩文件并删除该变量都像魅力一样工作。谢谢! – eskalera