Eclipse 中使用 mvn 管理java project
1. install mvn:
sudo apt-get install maven2
2. install mvn plugin in eclipse:
http://m2eclipse.sonatype.org/sites/m2e
3. get pom.xml file
you can write the pom.xml by yourself or download existing file from SCM server
4. generate the eclipse project files from pom.xml
mvn eclipse:eclipse
or:
mvn -DdownloadSources=true -DdownloadJavadocs=true -DoutputDirectory=target/eclipse-classes eclipse:eclipse
5. import project from eclipse
now you can get all the dependency jar files and make the project compiled.