Sha256: 740a151af410dfadef95c268760f41279f25b574cf542dec1b074c2ab749cdd3

Contents?: true

Size: 685 Bytes

Versions: 20

Compression:

Stored size: 685 Bytes

Contents

command :list do |c|
  c.summary = 'List all droplet creation parameters'
  c.syntax = 'ops list |provider|'
  c.description = "List all possible providers, and all possible params for a provider if |provider| is defined"
  c.example "List all possible providers", "ops list"
  c.example "List all possible arguments for DigitalOcean", "ops list digital_ocean"
  c.action do |args, options|
    if args[0]
      say "\nDESCRIPTION: This shows a list in the format '- [id] =>  [description]'. Use [id] values to create your host file in #{Ops::HOSTS_DIR}/[dns_name].yml\n"
      ProviderFactory.build(args[0]).list_params
    else
      ProviderFactory.list_providers
    end

  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
open-dock-0.1.18 lib/open-dock/commands/list.rb
open-dock-0.1.17 lib/open-dock/commands/list.rb
open-dock-0.1.16 lib/open-dock/commands/list.rb
open-dock-0.1.15 lib/open-dock/commands/list.rb
open-dock-0.1.14 lib/open-dock/commands/list.rb
open-dock-0.1.13 lib/open-dock/commands/list.rb
open-dock-0.1.11 lib/open-dock/commands/list.rb
open-dock-0.1.10 lib/open-dock/commands/list.rb
open-dock-0.1.9 lib/open-dock/commands/list.rb
open-dock-0.1.8 lib/open-dock/commands/list.rb
open-dock-0.1.7 lib/open-dock/commands/list.rb
open-dock-0.1.6 lib/open-dock/commands/list.rb
open-dock-0.1.5 lib/open-dock/commands/list.rb
open-dock-0.1.3 lib/open-dock/commands/list.rb
open-dock-0.1.2 lib/open-dock/commands/list.rb
open-dock-0.1.1 lib/open-dock/commands/list.rb
open-dock-0.1.0 lib/open-dock/commands/list.rb
open-dock-0.0.15 lib/open-dock/commands/list.rb
open-dock-0.0.14 lib/open-dock/commands/list.rb
open-dock-0.0.13 lib/open-dock/commands/list.rb