Would it be possible for the GPG password to be saved, so that I am not prompted for the passphrase everytime I make a git commit?
The passphrase itself is not stored anywhere and thus cannot be displayed. The decryption process works anyway by repeatedly applying a secure hash algorithm to a concatenation of the passphrase being input and a salt value (a random number) read from the key ring.
You can disable this by running git config commit. gpgsign false This sets the configuration locally instead of globally.
About GPG keys GPG is a command line tool used together with Git to encrypt and sign commits or tags to verify contributions in Bitbucket. In order to use GPG keys with Bitbucket, you'll need generate a GPG key locally, add it to your Bitbucket account, and also set it up for use with Git.
You can set a timeout period for gpg-agent in ~/.gnupg/gpg-agent.conf
with this line:
default-cache-ttl 3600
That would tell gpg-agent to store the passphrase for one hour. You wouldn't want it to be indefinite, but not constantly typing it is of benefit too.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With