This post will contain some Maven snippets that i use and forget regularly (similar to my Git Post).
Download the sources of all dependencies of a project if available:
Download the JavaDoc for all dependencies if available:
mvn dependency:resolve -Dclassifier=javadoc -Dtype=jar
Check for updates of all direct dependencies:
Skip signing of artifacts (i.e. for a local install of a snapshot)
mvn -Dgpg.skip=true install
If you need to branch from a tag and fix some bugs, i recommend to checkout the tag and then use
mvn release:branch -DbranchName=my-branch -DupdateBranchVersions=true -DupdateWorkingCopyVersions=false
This creates a new branch “my-branch” and updates the version to x.x.x-SNAPSHOT in the branch and leaves the working copy as is.
Run single tests or single methods in tests: Nice, official documentation right here
Execute a goal of a single, configured plugin with a given execution id:
List goals by the order they will execute
Group goals by phase
Group goals by plugin
Last update: 2018/01/09