diff --git a/lib/vagrant/plugin/v2/command.rb b/lib/vagrant/plugin/v2/command.rb index 146e502ac..2b0248b62 100644 --- a/lib/vagrant/plugin/v2/command.rb +++ b/lib/vagrant/plugin/v2/command.rb @@ -188,7 +188,7 @@ module Vagrant machines.reverse! if options[:reverse] # Go through each VM and yield it! - color_order = [:white] + color_order = [:default] color_index = 0 machines.each do |machine| diff --git a/lib/vagrant/ui.rb b/lib/vagrant/ui.rb index 221913492..c6dec9078 100644 --- a/lib/vagrant/ui.rb +++ b/lib/vagrant/ui.rb @@ -323,7 +323,7 @@ module Vagrant # is bolded. bold = !!opts[:bold] colorseq = "#{bold ? 1 : 0 }" - if opts[:color] + if opts[:color] && opts[:color] != :default color = COLORS[opts[:color]] colorseq += ";#{color}" end diff --git a/test/unit/vagrant/ui_test.rb b/test/unit/vagrant/ui_test.rb index fed518da1..c7c75d158 100644 --- a/test/unit/vagrant/ui_test.rb +++ b/test/unit/vagrant/ui_test.rb @@ -114,6 +114,11 @@ describe Vagrant::UI::Colored do subject.output("foo") end + it "doesn't use a color if default color" do + subject.should_receive(:safe_puts).with("\033[0mfoo\033[0m", anything) + subject.output("foo", color: :default) + end + it "bolds output without color if specified" do subject.should_receive(:safe_puts).with("\033[1mfoo\033[0m", anything) subject.output("foo", bold: true)