Class: TerraformEnterprise::Commands::OrganizationsCommand

Inherits:
Command
  • Object
show all
Defined in:
lib/terraform-enterprise/commands/organizations_command.rb

Constant Summary collapse

CMD_STR =
STRINGS[:organizations][:commands]

Instance Method Summary collapse

Instance Method Details

#create(name, email) ⇒ Object



15
16
17
# File 'lib/terraform-enterprise/commands/organizations_command.rb', line 15

def create(name, email)
  render client.organizations.create(name: name, email: email)
end

#delete(name) ⇒ Object



25
26
27
# File 'lib/terraform-enterprise/commands/organizations_command.rb', line 25

def delete(name)
  render client.organizations.delete(name:name)
end

#get(name) ⇒ Object



20
21
22
# File 'lib/terraform-enterprise/commands/organizations_command.rb', line 20

def get(name)
  render client.organizations.get(name:name)
end

#listObject



10
11
12
# File 'lib/terraform-enterprise/commands/organizations_command.rb', line 10

def list
  render client.organizations.list, only: [:id, :name, 'created-at', :email]
end