mirror of
https://github.com/AppleCommander/bastools.git
synced 2025-02-07 03:30:30 +00:00
Adding a version to the BT API.
This commit is contained in:
parent
0a6c669907
commit
9446fe4126
@ -10,6 +10,15 @@ dependencies {
|
||||
testImplementation 'junit:junit:4.12'
|
||||
}
|
||||
|
||||
jar {
|
||||
manifest {
|
||||
attributes(
|
||||
'Implementation-Title': 'B/BAS Tokenizer',
|
||||
'Implementation-Version': "${version} (${new Date().format('yyyy-MM-dd HH:mm')})"
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
task javadocJar(type: Jar) {
|
||||
classifier = 'javadoc'
|
||||
from javadoc
|
||||
|
@ -1,10 +1,16 @@
|
||||
package io.github.applecommander.bastokenizer.tools.bt;
|
||||
|
||||
import io.github.applecommander.applesingle.AppleSingle;
|
||||
import io.github.applecommander.bastokenizer.api.BasTokenizer;
|
||||
import picocli.CommandLine.IVersionProvider;
|
||||
|
||||
/** Display version information. Note that this is dependent on Gradle configuration. */
|
||||
public class VersionProvider implements IVersionProvider {
|
||||
public String[] getVersion() {
|
||||
return new String[] { Main.class.getPackage().getImplementationVersion() };
|
||||
return new String[] {
|
||||
String.format("BT CLI: %s", Main.class.getPackage().getImplementationVersion()),
|
||||
String.format("BT API: %s", BasTokenizer.VERSION),
|
||||
String.format("AppleSingle API: %s", AppleSingle.VERSION)
|
||||
};
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user