Skip to content

Instantly share code, notes, and snippets.

@jwliechty
Created November 6, 2015 20:59
Show Gist options
  • Save jwliechty/5afef1815ea6ee3cefb2 to your computer and use it in GitHub Desktop.
Save jwliechty/5afef1815ea6ee3cefb2 to your computer and use it in GitHub Desktop.
Get maven version of a project via command line
mvn org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version -Dexpression=project.artifactId -f '/path/to/pom.xml' 2>/dev/null | grep -Ev '^(\[|Download\w+:)'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment