From 740877065a8fc0b777cc7aa51b4fb074307affbd Mon Sep 17 00:00:00 2001 From: Matt Wrock Date: Fri, 5 Jun 2015 05:03:29 -0700 Subject: [PATCH] marshall back command output when passing a command to ps --- plugins/commands/ps/command.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/commands/ps/command.rb b/plugins/commands/ps/command.rb index 3bcc41ba8..ee021d0ed 100644 --- a/plugins/commands/ps/command.rb +++ b/plugins/commands/ps/command.rb @@ -50,9 +50,11 @@ module VagrantPlugins end if !options[:command].nil? - out_code = machine.communicate.execute(options[:command]) + out_code = machine.communicate.execute(options[:command].dup) do |type,data| + machine.ui.detail(data) if type == :stdout + end if out_code == 0 - machine.ui.detail("Command: #{options[:command]} executed succesfully with output code #{out_code}.") + machine.ui.success("Command: #{options[:command]} executed succesfully with output code #{out_code}.") end next end