Get Console Output

Discussion in 'Plugin Development' started by Snowl, Feb 14, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    Snowl

    Well, for my plugin milkAdmin I need to get the console output. I considered looking at server.log but that is all the servers logs, ever. Is there a way to get the current consoles output?
     
  2. Offline

    xpansive

    I don't think thats possible with java. You could get only the most recent entries from server.log, that would probably be the best way to do it.
     
  3. Offline

    eisental

    You can try Logger.addHandler(). You get the logger with Logger.getLogger("Minecraft"). I think it should work with server messages and most plugins but only with those that are nice enough to use the logger and not System.out.
    You can also hijack the System.out with System.setOut(PrintStream out).
     
    victor2748 likes this.
Thread Status:
Not open for further replies.

Share This Page