I have Windows7 and I'm trying to install maven and test it.
But I realised that I have a problem with JAVA and I have to it solve first.
I do Start->Run->cmd
and when I type in the command line,
C:\>mvn clean
I get the following error
ERROR: JAVA_HOME not found in your environment. Please set the JAVA_HOME variable
in your environment to match the location of your Java installation
So i say: Let's set the PATH for Java and i did:
Start->Control Panel->System->Advanced System Settings->Environment Variable->System Variables
Edit the PATH variable
C:\Program Files\Java\jdk1.6.0_32;C:\apache-maven-3.0.4\bin; But then i get the same error when i do:
C:>mvn clean
Then i typed in the cmd prompt:
C:\>java -version
java version "1.7.0_07"
Java(TM) SE Runtime Environment (build 1.7.0_07-b11)
And I realise that the Java version that is running is not located under the C:\Program Files\Java
directory
The only JDKs I have are: jdk1.6.0_29 jdk1.6.0_32
Then I did Run->cmd
C:>where java C:\Windows\System32\java.exe (Recently i downloaded IDE Eclipse and IDE IntelliJ and i don't know if these apps come with the JDK).
c:\ >javac
It's working fine
C:>java
this is also working fine
How to resolve above problem any one can help me out?