class Trustworthy::CLI::AddKey
Public Class Methods
description()
click to toggle source
# File lib/trustworthy/cli/add_key.rb, line 6 def self.description 'Add a new user key for a master key' end
Public Instance Methods
run(args)
click to toggle source
# File lib/trustworthy/cli/add_key.rb, line 10 def run(args) options = parse_options('add-key', args) say('Adding a new key to master key') prompt = Trustworthy::Prompt.new(options[:config_file], $terminal) master_key = prompt.unlock_master_key key = master_key.create_key username = prompt.add_user_key(key) say("Added #{username}") end