Skip to content
Permalink
Browse files

Actually hook up the version

  • Loading branch information...
me4502 committed Jul 26, 2019
1 parent d0db9e3 commit a7afa675c56f2fa237fcd81f1e6e6eaa9c9360c5
@@ -13,7 +13,7 @@ dependencies {
tasks.named<Jar>("jar") {
manifest {
attributes(
"WorldEdit-Version" to project.version,
"Implementation-Version" to project.version,
"Main-Class" to "com.sk89q.worldedit.cli.CLIWorldEdit"
)
}
@@ -56,11 +56,14 @@
import java.io.InputStream;
import java.io.SequenceInputStream;
import java.io.UncheckedIOException;
import java.net.URL;
import java.net.URLClassLoader;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.StandardOpenOption;
import java.util.Map;
import java.util.Scanner;
import java.util.jar.Manifest;

/**
* The CLI implementation of WorldEdit.
@@ -74,6 +77,7 @@
private CLIPlatform platform;
private CLIConfiguration config;
private Path workingDir;
private String version;

private Actor commandSender;

@@ -220,7 +224,10 @@ public File getWorkingDir() {
* @return a version string
*/
String getInternalVersion() {
return ":shrug:";
if (version == null) {
version = getClass().getPackage().getImplementationVersion();
}
return version;
}

public void run(InputStream inputStream) {

0 comments on commit a7afa67

Please sign in to comment.
You can’t perform that action at this time.