Commit Graph

3 Commits

Author SHA1 Message Date
Minecrell
ca2b4c592f Continue reading from console input after EOT
There is usually no reason to stop reading from the console, so
preventing console input after EOT can be extremely confusing.

To prevent this, we can simply ignore the exception thrown by
JLine and continue reading normally.
2017-06-14 09:47:10 +02:00
Minecrell
56dcc3fcc7 Remove unneeded WINDOWS_COMPAT ConsoleAppender
It was originally added in Bukkit/CraftBukkit@6aafe7c5a1 as a
workaround for BUKKIT-4956 to fix console output on Windows.

I believe the original issue was related to LOG4J2-965 and fixed
in apache/logging-log4j2@d04659c. Minecraft 1.12 finally updated
the Log4J version so this issue is no longer present.

Console output is still working fine on Windows after removing this.
2017-06-13 10:36:35 +02:00
Minecrell
de2af506f3 Improve console implementation
Rewrite console improvements (console colors, tab completion,
persistent input line, ...) using JLine 3.x and TerminalConsoleAppender.

New features:
  - Support console colors for Vanilla commands
  - Add console colors for warnings and errors
  - Server can now be turned off safely using CTRL + C. JLine catches
    the signal and the implementation shuts down the server cleanly.
  - Support console colors and persistent input line when running in
    IntelliJ IDEA

Other changes:
  - Update JLine to 3.3.1 (from 2.12.1)
  - Server starts 1-2 seconds faster thanks to optimizations in Log4j
    configuration
2017-06-11 14:31:21 +02:00