This commit is contained in:
JFronny 2021-10-31 17:30:51 +01:00
parent 5171cb7d5f
commit 38392dc9e2
No known key found for this signature in database
GPG Key ID: BEC5ACBBD4EE17E5
4 changed files with 6 additions and 6 deletions

View File

@ -28,6 +28,8 @@ build_test:
paths:
- build/libs
- latest.jar
- wrapper.jar
- wrapper.exe
- latest-linux.jar
- latest-macos.jar
- latest-windows.jar

View File

@ -7,7 +7,7 @@ plugins {
}
application {
mainClass = 'io.gitlab.jfronny.inceptum.wrapper.Wrapper'
mainClass = 'io.gitlab.jfronny.inceptum.Wrapper'
}
repositories {

View File

@ -21,9 +21,9 @@ public class Wrapper {
p = Path.of(path).getParent();
} else {
System.out.println("Not running in a jar, using ./run");
p = Path.of("./run");
p = Path.of(".");
}
p = p.resolve("libraries/io/gitlab/jfronny/inceptum/Inceptum");
p = p.resolve("run/libraries/io/gitlab/jfronny/inceptum/Inceptum");
if (!Files.exists(p)) {
System.err.println("No Inceptum jar was identified");
UpdateInfo ui = UpdateChecker.check(UpdateChannel.Stable, new ComparableVersion("0"), OSCheck.OS.getMojName(), c -> {}, System.err::println, (s, e) -> {

View File

@ -6,10 +6,8 @@ public class ComparableVersion implements Comparable<ComparableVersion> {
public ComparableVersion(String string) {
this.string = string;
this.numbers = new int[3];
String[] split = string.split("[.+]+");
this.numbers = new int[split.length];
for (int i = 0; i < split.length; i++) {
try {
numbers[i] = Integer.parseInt(split[i]);