   (:import [jline.console ConsoleReader]
            [java.util Timer TimerTask])
   (:gen-class))
+(refer-logging)
 
 
 ;;; Globals for REPL access. A necessary evil.

  See the documentation on the handle-command for more info on this.
  When this function returns (of which its value is of no value, pun
  intended), the `shutdown` command has been issued."
  [systems]
  (let [jline (ConsoleReader. System/in @#'containium.systems.logging/stdout)]
    (loop []
      (let [[command & args] (commands/parse-quoted (.readLine jline "containium> "))]

                                         (logging/stdout-command-logger (:logging systems) command))
                (catch Throwable t
                  (ex/exit-when-fatal t)
                  (error logging "Error handling command" command ":")
                  (error logging t)))
              (recur)))))))


