1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

[core] Fix display_stdout to process multiple lines output.

This commit is contained in:
Rupak Ganguly 2012-02-13 19:07:17 -05:00
parent 6bf0465fe1
commit f10a3488f2

View file

@ -96,7 +96,12 @@ module Fog
attr_accessor :command, :stderr, :stdout, :status attr_accessor :command, :stderr, :stdout, :status
def display_stdout def display_stdout
Formatador.display_line(stdout.split("\r\n")) data = stdout.split("\r\n")
if data.is_a?(String)
Formatador.display_line(data)
elsif data.is_a?(Array)
Formatador.display_lines(data)
end
end end
def display_stderr def display_stderr