class Shelly::CLI::Organization

Public Instance Methods

add() click to toggle source
# File lib/shelly/cli/organization.rb, line 34
def add
  create_new_organization(options)
rescue Client::ValidationException => e
  e.each_error { |error| say_error error, :with_exit => false }
  exit 1
end
list() click to toggle source
# File lib/shelly/cli/organization.rb, line 12
def list
  user = Shelly::User.new
  organizations = user.organizations
  say "You have access to the following organizations and clouds:", :green
  say_new_line
  organizations.each do |organization|
    say organization.name, :green
    if organization.apps.present?
      print_table(apps_table(organization.apps), :ident => 2, :colwidth => 35)
    else
      print_wrapped "No clouds", :ident => 2
    end
  end
end