[
https://issues.apache.org/jira/browse/RAT-381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17847691#comment-17847691
]
Philipp Ottlinger commented on RAT-381:
---------------------------------------
We could use a direct Java way, such as
*
https://github.com/ottlinger/spamschutz/blob/master/src/main/resources/filtered/Version.java
* https://github.com/ottlinger/spamschutz/blob/master/pom.xml#L419
and remove any SNAPSOT suffixes in order to properly show the version, that is
used.
The longer I think about it the more I ask myself if this information is really
necessary?
If I call a apache-rat-foo-1.2.3.jar I should be well aware of using v1.2.3?
What's the purpose of adding this feature? Just to show the version in
CLI-calls?
If that's the case we should extract it from the JAR's manifest?
https://stackoverflow.com/questions/5834794/how-to-check-the-version-of-jar-file
I just tried out locally:
Manifest-Version: 1.0
Implementation-Title: Apache Creadur Rat::Plugin4Maven
Implementation-Version: 0.17-SNAPSHOT
Specification-Vendor: Apache Software Foundation
Specification-Title: Apache Creadur Rat::Plugin4Maven
Build-Jdk-Spec: 1.8
Created-By: Maven JAR Plugin 3.4.0
Specification-Version: 0.17
Implementation-Vendor: Apache Software Foundation
is generated into the JAR. Maybe we coulr refernce Specification-Version:0.17?
> Add accurate version info to the Command line parsing.
> ------------------------------------------------------
>
> Key: RAT-381
> URL: https://issues.apache.org/jira/browse/RAT-381
> Project: Apache Rat
> Issue Type: Sub-task
> Components: Client - cli, configuration
> Affects Versions: 0.16.1
> Reporter: Claude Warren
> Assignee: Claude Warren
> Priority: Minor
>
> The output from the client help shows the version number pattern, not the
> actual version number.
> This change is to figure out how to store the maven version number within the
> jar so that we can report it in help and other associated places.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)