search

Home  >  Q&A  >  body text

ssh - Source Tree在pull/git时提示输入密码

如图所示,不用过用命令行就正常,生成ssh key时,passwordphrase木有设置米密码,为空

迷茫迷茫2764 days ago900

reply all(2)I'll reply

  • PHP中文网

    PHP中文网2017-04-22 09:02:36

    Okay, after working on it for a long time, I finally got it. It turns out that souretree cannot store ssh key, but reads the ssh key from the specified location (~/.ssh/ directory). The most important thing is that it reads the ssh key by default. Private key named id_rsa! ! ! And my private key does not have this name, so sourcetree cannot find the specified private key, and the authentication cannot pass, thus constantly prompting you to enter your password. After changing the private key name to id_rsa, everything finally became normal.

    Reference link: [Notes] Let SourceTree read a custom SSH key (need to bypass the firewall, here is a Google snapshot)

    reply
    0
  • PHP中文网

    PHP中文网2017-04-22 09:02:36

    You can specify the ssh key to use by configuring ~/.ssh/config
    Host xxxx.xxx
    IdentityFile ~/.ssh/id_rsa

    reply
    0
  • Cancelreply