From 7d08ea4c09a020e5721943eb7454d431ba08c4b2 Mon Sep 17 00:00:00 2001 From: Ethan Frey Date: Tue, 20 Jun 2017 18:50:53 +0200 Subject: [PATCH] Fixed all tests and binaries to compile --- cmd/new.go | 2 +- cmd/root.go | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/cmd/new.go b/cmd/new.go index 033410e6a..0dd481e01 100644 --- a/cmd/new.go +++ b/cmd/new.go @@ -48,7 +48,7 @@ func newPassword(cmd *cobra.Command, args []string) error { return err } - info, err := GetKeyManager().Create(name, pass, algo) + info, _, err := GetKeyManager().Create(name, pass, algo) if err == nil { printInfo(info) } diff --git a/cmd/root.go b/cmd/root.go index 33153d850..cd1913273 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -48,10 +48,15 @@ func GetKeyManager() keys.Manager { // store the keys directory rootDir := viper.GetString(cli.HomeFlag) keyDir := filepath.Join(rootDir, KeySubdir) + + // TODO: smarter loading??? with language and fallback? + codec := keys.MustLoadCodec("english") + // and construct the key manager manager = cryptostore.New( cryptostore.SecretBox, filestorage.New(keyDir), + codec, ) } return manager