Class: SecretHub::Commands::Repo

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

Instance Method Summary collapse

Methods inherited from Base

#github

Instance Method Details

#delete_commandObject



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

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

#list_commandObject



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

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

#save_commandObject



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

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