dont try to colorize windows
This commit is contained in:
@@ -31,7 +31,7 @@ class Foreman::Engine::CLI < Foreman::Engine
|
|||||||
|
|
||||||
def color?
|
def color?
|
||||||
return true if @@color_force
|
return true if @@color_force
|
||||||
return true if Foreman.windows?
|
return false if Foreman.windows?
|
||||||
return false unless self.respond_to?(:isatty)
|
return false unless self.respond_to?(:isatty)
|
||||||
self.isatty && ENV["TERM"]
|
self.isatty && ENV["TERM"]
|
||||||
end
|
end
|
||||||
@@ -49,9 +49,8 @@ class Foreman::Engine::CLI < Foreman::Engine
|
|||||||
|
|
||||||
def startup
|
def startup
|
||||||
@colors = map_colors
|
@colors = map_colors
|
||||||
proctitle "foreman: master"
|
proctitle "foreman: master" unless Foreman.windows?
|
||||||
require "win32console" if Foreman.windows?
|
Color.enable($stdout, options[:color])
|
||||||
Color.enable($stdout, options[:color]) unless $stdout.respond_to?(:color?)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def output(name, data)
|
def output(name, data)
|
||||||
|
|||||||
Reference in New Issue
Block a user