SmartGit won't authenticate with ssh

后端 未结 5 1912
予麋鹿
予麋鹿 2020-12-10 02:39

I have a webserver with gitolite installed and where i login using my ssh key. Normally i just use git on the server itself using the command line but for a new project i ne

5条回答
  •  猫巷女王i
    2020-12-10 03:31

    If you're using SmartGit on MacOS X, this problem causes an unexpected dialog to be displayed in the Finder:

    "SSH - Enter passphrase for key '/Users/username/.ssh/id_rsa':"

    And it pops up when SmartGit is launched. It looks like this:

    It's odd and confusing how looks like a Finder dialog, with no reference at all to SmartGit. It's usually caused by the SSH key password not being stored in the Keychain Access app. That's where SmartGit will look for it. You'll need to add it in there, like this:

    ssh-add -K ~/.ssh/id_rsa    (assuming id_rsa is your private key file)
    

    The above command is sometimes needed after restarting your computer. See also these guides:

    • https://apple.stackexchange.com/questions/48502/how-can-i-permanently-add-my-ssh-private-key-to-keychain-so-it-is-automatically
    • https://superuser.com/questions/88470/how-to-use-mac-os-x-keychain-with-ssh-keys
    • SSH Key - Still asking for password and passphrase

提交回复
热议问题