Last active
February 15, 2025 07:19
-
-
Save jirikrepl/771689ef58445ac4f741846d3e7403f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# configure git credentials manager to work with GPG | |
# usefull for sessions without GUI | |
# https://github.com/GitCredentialManager/git-credential-manager | |
# https://github.com/GitCredentialManager/git-credential-manager/blob/main/docs/credstores.md#gpgpass-compatible-files | |
# install pass | |
sudo apt install pass | |
# generate gpg key pair | |
gpg --gen-key | |
# initiate pass with your gpg key pair (ID is very long string) | |
pass init <gpg-key-pair-id> | |
# add this to your ~/.bashrc, so you can you can use GPG in your terminal witout GUI | |
vim ~/.bashrc | |
export GPG_TTY=$(tty) | |
# set github password manager to use pass | |
git config --global credential.credentialStore pass | |
# connect via SSH and use device authentication |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@jirikrepl I believe on line 21, instead of
pass
it should begpg
:....otherwise this is very helpful. Thanks!