Class: SecretHub::Commands::Org

Inherits:
Base
  • Object
show all
Defined in:
lib/secret_hub/commands/org.rb

Instance Method Summary collapse

Methods inherited from Base

#github

Instance Method Details

#delete_commandObject



36
37
38
39
# File 'lib/secret_hub/commands/org.rb', line 36

def delete_command
  github.delete_org_secret org, key
  say "Deleted b`#{org}` m`#{key}`"
end

#list_commandObject



24
25
26
27
28
29
# File 'lib/secret_hub/commands/org.rb', line 24

def list_command
  say "b`#{org}`:"
  github.org_secrets(org).each do |secret|
    say "- m`#{secret}`"
  end
end

#save_commandObject



31
32
33
34
# File 'lib/secret_hub/commands/org.rb', line 31

def save_command
  github.put_org_secret org, key, value
  say "Saved b`#{org}` m`#{key}`"
end