sudo apt install pass
gpg --list-keys
gpg --generate-key
pass init ABCDEFGHIJKLMNOPQRSTUV1234where ABCDEFGHIJKLMNOPQRSTUV1234 is the name of the key.
pass generate keyfolder/newkeyList the passwords.
passCopy a password to the clipboard.
pass keyfolder/newkey -cFor more commands:
man pass
Connect Pass to Git and it is easy to keep track of passwords with multiple machines.
gpg --export --output public.key ABCDEFGHIJKLMNOPQRSTUV1234 gpg --export-secret-key --output private.key ABCDEFGHIJKLMNOPQRSTUV1234where ABCDEFGHIJKLMNOPQRSTUV1234 is your key name.
gpg --import public.key gpg --import private.key
gpg --list-keys
pass init ABCDEFGHIJKLMNOPQRSTUV1234
pass git init pass git remote add origin git@repo.com:myname/pass-store
pass git pull origin master --allow-unrelated-histories pass git commit -am "firstcommit"If Git complains about “divergent branches” just choose the “merge” reconcileing and repeat the command.
pass git push --set-upstream origin master
pass git pull pass git pushIt can be the case that you have to raise the trust level of the public key. For that, check this article.
References: