1
0
Fork 0
mirror of https://github.com/nishiki/manage-password.git synced 2024-11-23 05:47:53 +00:00

add an option for add a share gpg key

This commit is contained in:
Adrien Waksberg 2016-12-12 23:13:32 +01:00
parent 3575cd9bd7
commit bf356f4d6f
3 changed files with 8 additions and 0 deletions

View file

@ -31,6 +31,10 @@ values = {}
OptionParser.new do |opts|
opts.banner = "#{I18n.t('option.usage')}: mpw wallet [options]"
opts.on('-a', '--add-gpg-key NAME', I18n.t('option.add_gpg_key')) do |gpg_key|
options[:gpg_key] = gpg_key
end
opts.on('-c', '--config PATH', I18n.t('option.config')) do |config|
options[:config] = config
end
@ -84,6 +88,8 @@ cli.load_config
if not options[:list].nil?
cli.list_wallet
elsif not options[:gpg_key].nil?
cli.add_key(options[:gpg_key])
else
cli.get_wallet(options[:wallet])
cli.decrypt

View file

@ -50,6 +50,7 @@ en:
option:
add: "Add an item or key"
add_gpg_key: "Share the wallet with an other GPG key (name or file path)"
alpha: "Use letter to generate a password"
config: "Specify the configuration file to use"
clipboard: "Disable the clipboard feature"

View file

@ -50,6 +50,7 @@ fr:
option:
add: "Ajoute un élément ou une clé"
add_gpg_key: "Partage le portefeuille avec une autre clé GPG (nom ou fichier)"
alpha: "Utilise des lettres dans la génération d'un mot de passe"
config: "Spécifie le fichier de configuration à utiliser"
clipboard: "Désactive la fonction presse papier"