Skip to content

Instantly share code, notes, and snippets.

@filevich
Last active August 31, 2022 22:13
Show Gist options
  • Save filevich/64df41d9f26184f2f2160aa19b8f6ba0 to your computer and use it in GitHub Desktop.
Save filevich/64df41d9f26184f2f2160aa19b8f6ba0 to your computer and use it in GitHub Desktop.
git secure credential store

sudo apt install libsecret-1-0 libsecret-1-dev

cd /usr/share/doc/git/contrib/credential/libsecret

sudo make

git config --global credential.helper /usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret

When you git clone, git fetch, git pull, or git push to a remote repository using HTTPS URLs on the command line, Git will ask for your GitHub username and password. When Git prompts you for your password, enter your personal access token (PAT).

Create a PAT here or at Settings > Developer settings > Personal access tokens

Luego, que el ~/.gitconfig quede asi:

[credential]
        helper = /usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret
[user]
        email = [email protected]
        name = J.P. Filevich
[init]
        defaultBranch = main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment