diff options
author | Dinnerbone <dinnerbone@dinnerbone.com> | 2011-02-25 16:12:38 +0000 |
---|---|---|
committer | Dinnerbone <dinnerbone@dinnerbone.com> | 2011-02-25 16:12:38 +0000 |
commit | 57338bee5205c157c1cf83bf50ab513f9d3f69d9 (patch) | |
tree | aa178c1cd5d0fc35fba7e76b07f1a72f71637bbc /src/main/java/net/minecraft/server/ConsoleLogManager.java | |
parent | 659fa9eaf9ccfcda12ee9bc4b7dfa589884927da (diff) | |
download | craftbukkit-57338bee5205c157c1cf83bf50ab513f9d3f69d9.tar craftbukkit-57338bee5205c157c1cf83bf50ab513f9d3f69d9.tar.gz craftbukkit-57338bee5205c157c1cf83bf50ab513f9d3f69d9.tar.lz craftbukkit-57338bee5205c157c1cf83bf50ab513f9d3f69d9.tar.xz craftbukkit-57338bee5205c157c1cf83bf50ab513f9d3f69d9.zip |
Much better console interaction. History, no more losing the command, colours, inline editing, etc. Shorter log output to console (but not to file).
Diffstat (limited to 'src/main/java/net/minecraft/server/ConsoleLogManager.java')
-rw-r--r-- | src/main/java/net/minecraft/server/ConsoleLogManager.java | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/net/minecraft/server/ConsoleLogManager.java b/src/main/java/net/minecraft/server/ConsoleLogManager.java index 6de400b4..641c8ca7 100644 --- a/src/main/java/net/minecraft/server/ConsoleLogManager.java +++ b/src/main/java/net/minecraft/server/ConsoleLogManager.java @@ -6,6 +6,9 @@ import java.util.logging.Level; import java.util.logging.Logger; import java.util.logging.Handler; // CraftBukkit +import jline.ConsoleReader; +import org.bukkit.craftbukkit.util.ShortConsoleLogFormatter; +import org.bukkit.craftbukkit.util.TerminalConsoleHandler; public class ConsoleLogManager { @@ -14,11 +17,12 @@ public class ConsoleLogManager { public ConsoleLogManager() {} - public static void a() { + // Craftbukkit - change of method signature! + public static void a(ConsoleReader reader) { ConsoleLogFormatter consolelogformatter = new ConsoleLogFormatter(); a.setUseParentHandlers(false); - ConsoleHandler consolehandler = new ConsoleHandler(); + ConsoleHandler consolehandler = new TerminalConsoleHandler(reader); // CraftBukkit start for (Handler handler: global.getHandlers()) { @@ -26,7 +30,7 @@ public class ConsoleLogManager { } // CraftBukkit end - consolehandler.setFormatter(consolelogformatter); + consolehandler.setFormatter(new ShortConsoleLogFormatter()); // Craftbukkit a.addHandler(consolehandler); global.addHandler(consolehandler); // CraftBukkit |