Git on Bitbucket: Always asked for password, even after uploading my public SSH key

前端 未结 15 1372
情书的邮戳
情书的邮戳 2020-12-22 17:32

I uploaded my ~/.ssh/id_rsa.pub to Bitbucket\'s SSH keys as explained, but Git still asks me for my password at every operation (such as git pull).

15条回答
  •  情书的邮戳
    2020-12-22 18:16

    As explained here, if you clone with SSH url, you don't need to enter username / password each time you push / pull. Check above answer by @manojlds

    But if you want to clone with HTTPS and want to avoid entering username / password each time, you can store credentials into cache with below command:

    git config --global credential.helper 'cache --timeout 3600'

    where 3600 (seconds) means 1 hour, you may change it as per your requirement.

提交回复
热议问题