From 92f19588f5be4f2844dfd228ada95556e00b6cfe Mon Sep 17 00:00:00 2001 From: Osiris Team Date: Tue, 1 Oct 2024 15:50:21 +0200 Subject: [PATCH] 8.3.0 - update mc server updater, now supports more software, thanks to @minionguyjpro - remove ssh logging while stopping --- pom.xml | 4 ++-- src/main/java/JPM.java | 2 +- .../java/com/osiris/autoplug/client/console/Commands.java | 4 ++-- .../java/com/osiris/autoplug/client/tasks/SSHManager.java | 8 ++++++-- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/pom.xml b/pom.xml index 17daee12..da5dc501 100644 --- a/pom.xml +++ b/pom.xml @@ -11,11 +11,11 @@ AUTO-GENERATED FILE, CHANGES SHOULD BE DONE IN ./JPM.java or ./src/main/java/JPM 4.0.0 com.osiris.autoplug.client AutoPlug-Client - 8.2.12 + 8.3.0 UTF-8 8 - 8.2.12 + 8.3.0 com.osiris.autoplug.client.Main 2.0.13 AutoPlug-Client diff --git a/src/main/java/JPM.java b/src/main/java/JPM.java index 12ef0a07..8c10e83a 100644 --- a/src/main/java/JPM.java +++ b/src/main/java/JPM.java @@ -21,7 +21,7 @@ public ThisProject(List args) { // Override default configurations this.groupId = "com.osiris.autoplug.client"; this.artifactId = "AutoPlug-Client"; - this.version = "8.2.12"; + this.version = "8.3.0"; this.mainClass = "com.osiris.autoplug.client.Main"; this.jarName = "AutoPlug-Client-original.jar"; this.fatJarName = "AutoPlug-Client.jar"; diff --git a/src/main/java/com/osiris/autoplug/client/console/Commands.java b/src/main/java/com/osiris/autoplug/client/console/Commands.java index c78a4702..1ed6f45f 100644 --- a/src/main/java/com/osiris/autoplug/client/console/Commands.java +++ b/src/main/java/com/osiris/autoplug/client/console/Commands.java @@ -307,13 +307,13 @@ public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IO new UtilsTasks().printResultsWhenDone(myManager.manager); return true; } else if (command.equals(".ssh stop")) { - SSHManager.stop(); + SSHManager.stop(true); return true; } else if (command.equals(".ssh start")) { SSHManager.start(true); return true; } else if (command.equals(".ssh restart")) { - SSHManager.stop(); + SSHManager.stop(true); SSHManager.start(true); return true; } else if (command.equals(".ping")) { // This is used for the SSH test, as well as for users to test if AutoPlug is running. diff --git a/src/main/java/com/osiris/autoplug/client/tasks/SSHManager.java b/src/main/java/com/osiris/autoplug/client/tasks/SSHManager.java index 2a3cfd18..51e6228e 100644 --- a/src/main/java/com/osiris/autoplug/client/tasks/SSHManager.java +++ b/src/main/java/com/osiris/autoplug/client/tasks/SSHManager.java @@ -84,10 +84,14 @@ public static synchronized boolean start(boolean force) { return false; } } + + public static boolean stop() { + return stop(false); + } - public static synchronized boolean stop() { + public static synchronized boolean stop(boolean printInfo) { if (!isRunning()) { - AL.info("SSH Server is not running!"); + if(printInfo) AL.info("SSH Server is not running!"); return true; } try {