Method: Xnlogic::UI::Shell#initialize

Defined in:
lib/xnlogic/ui/shell.rb

#initialize(options = {}) ⇒ Shell

Returns a new instance of Shell.



8
9
10
11
12
13
14
15
# File 'lib/xnlogic/ui/shell.rb', line 8

def initialize(options = {})
  if options["color"] == false || !STDOUT.tty?
    # FIXME: Apparently the basic shell now does color
    Thor::Base.shell = Thor::Shell::Basic
  end
  @shell = Thor::Base.shell.new
  @level = ENV['DEBUG'] ? "debug" : "info"
end