Sha256: 038056518b127c4ab359bcbfb04075da0df6e2bea93c0dcf420a5b9beef62ed9

Contents?: true

Size: 506 Bytes

Versions: 7

Compression:

Stored size: 506 Bytes

Contents

desc 'Show detailed type info'
arg_name 'type-id...'
command [:show] do |c|

  c.action do |global_options,options,args|
    
    if args.empty?
      raise "You must specify the types you want to show"
    end

    types = Type.find_or_call(args) do |id|
      warn "Couldn't find type #{id}"
    end

    table_opts = global_options.merge({
      :vertical => true,
      :fields => [:id, :handle, :status, :name, :ram, :disk, :cores, :description]
    })

    render_table(types, table_opts)

  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
bbcloud-0.11.2 lib/bbcloud/commands/types-show.rb
bbcloud-0.11.1 lib/bbcloud/commands/types-show.rb
bbcloud-0.11.0 lib/bbcloud/commands/types-show.rb
bbcloud-0.10.1 lib/bbcloud/commands/types-show.rb
bbcloud-0.9.2 lib/bbcloud/commands/types-show.rb
bbcloud-0.9.1 lib/bbcloud/commands/types-show.rb
bbcloud-0.9 lib/bbcloud/commands/types-show.rb