Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 9 lines (7 sloc) 320 Bytes
# parse POM from stdin and prints the version number
require "rexml/document"
require "rexml/xpath"
pom = $stdin
# if the POM doesn't define the version by itself, it's inherited from the parent
puts (pom.elements["/project/version"] || pom.elements["/project/parent/version"]).text
Jump to Line
Something went wrong with that request. Please try again.