How to prevent that the password to decrypt the private key has to be entered every time when using Git Bash on Windows?

后端 未结 7 2097
南方客
南方客 2020-11-28 17:20

I\'ve an automatic building service which download from a git private repository. The problem is that when it tries to clone repository it need to provide the password, beca

7条回答
  •  抹茶落季
    2020-11-28 18:02

    When I tried to push my code, I got the below error:

    $ git push origin dev
    
    remote: Too many invalid password attempts. Try logging in through the website with your password.
    fatal: unable to access 'https://naushadqamar-1@bitbucket.org/xxxx/xxxx-api.git/': The requested URL returned error: 403
    

    After a few hours of research, I found I need to use the below command:

    $ git config --global credential.helper cache
    

    After executing the above command, I got the prompt for entering my GitHub username and password. After providing the correct credentials, I am able to push my code.

提交回复
热议问题