Commands
- mvn eclipse:eclipse - does something to do with Eclipse, I'm not sure what
- mvn install - build the software into a .jar
- mvn test - run all the test cases
- mvn dependency:copy-dependencies - download and copy all dependencies into the target folder
Cannot execute mojo: resources. It requires a project with an existing pom.xml, but the build is not using one.
This means there is no "pom.xml" in the current directory. Perhaps you are not in the root directory of your project?
[INFO] Cannot find matching toolchain definitions for the following toolchain types:
jdk [ vendor='sun' version='1.5' ]
Please make sure you define the required toolchains in your ~/.m2/toolchains.xml file.
Maven is complaining that it can't find a Sun JDK 1.5. If you create a toolchains.xml in your .m2 directory with the following:
<toolchains> <toolchain> <type>jdk</type> <provides> <version>1.6</version> <vendor>sun</vendor> <id>i_hate_maven</id> </provides> <configuration> <jdkHome>C:program filesjavajdk1.6.0_02</jdkHome> </configuration> </toolchain> </toolchains>
This will still not work, because Maven is insisting on a 1.5 JVM, and supplying a 1.6 JVM is not appropriate. However, you can just copy and paste toolchain as follows. As far as I know, JVM 1.6 is backwards compatible.
<!-- I hate maven --> <toolchains> <toolchain> <type>jdk</type> <provides> <version>1.6</version> <vendor>sun</vendor> <id>i_hate_maven</id> </provides> <configuration> <jdkHome>C:program filesjavajdk1.6.0_02</jdkHome> </configuration> </toolchain> <toolchain> <type>jdk</type> <provides> <version>1.5</version> <vendor>sun</vendor> <id>i_hate_maven_2</id> </provides> <configuration> <jdkHome>C:program filesjavajdk1.6.0_02</jdkHome> </configuration> </toolchain> </toolchains>