Sha256: cb9e50fc9b6c94d2fa2012434bc075859167d7b8b9249da80427fb3ee3b2976a
Contents?: true
Size: 621 Bytes
Versions: 16
Compression:
Stored size: 621 Bytes
Contents
module Mccloud::Provider module Vmfusion module ProviderCommand def status(selection=nil,options=nil) env.ui.info "" 80.times { |i| printf "*"}; env.ui.info "" all_vms = ::Fission::VM.all all_running_vms = ::Fission::VM.all_running longest_vm_name = all_vms.max { |a,b| a.length <=> b.length } ::Fission::VM.all.each do |vm| status = all_running_vms.include?(vm) ? '[running]' : '[not running]' Fission.ui.output_printf "%-#{longest_vm_name.length}s %s\n", vm, status end end end #module end #module end #module
Version data entries
16 entries across 16 versions & 1 rubygems