I\'d like to download an artifact and its dependencies at the command line. I.e.
mvn [some plugin]:[goal] -DartifactId=[artifactId] -DgroupId=[groupId] -Dver
Example to download version 6.9.4 of TestNG to your local ~/.m2/repository (uses maven-dependency-plugin:get):
mvn org.apache.maven.plugins:maven-dependency-plugin:RELEASE:get \
-Dartifact=org.testng:testng:6.9.4:jar
Example to download version 4.11 of JUnit to your current working directory (uses maven-dependency-plugin:copy):
mvn org.apache.maven.plugins:maven-dependency-plugin:RELEASE:copy \
-Dartifact=junit:junit:4.11:jar