SSH Key - Still asking for password and passphrase

后端 未结 30 1440
孤街浪徒
孤街浪徒 2020-11-27 08:35

I\'ve been somewhat \'putting up\' with Github always asking for my username and password when I clone a repository. I want to bypass this step because it is an annoyance w

30条回答
  •  时光说笑
    2020-11-27 09:23

    Adding to the above answers. Had to do one more step on Windows for git to be able to use ssh-agent.

    Had to run the following command in powershell to update the environment variable:

    PS> [Environment]::SetEnvironmentVariable("GIT_SSH", "$((Get-Command ssh).Source)", [System.EnvironmentVariableTarget]::User)

    Restart VSCode, Powershell or whatever terminal you are using to activate the env variable.

    Complete instructions can be found [here] (https://snowdrift.tech/cli/ssh/git/tutorials/2019/01/31/using-ssh-agent-git-windows.html).

提交回复
热议问题