I have to manage a Java build, and I don't know how to best manage the software's version so that it can be displayed on an about dialog etc.
How do you people do it? We are using Maven, can I somehow reuse the version as defined in pom.xml? I'd also be interested to know how it's usually done with Ant.
You can get the Maven version of the jar by loading the pom.properties file. This is automatically created by Maven in the jars.
Should be located inside the jar, at this path
META-INF\maven\{groupId}\{artifactId}\pom.properties
This is mentioned a little bit more here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With