问题
I created public and private key with cygwins ssh and pasted the public key into bitbucket account.
ssh -T hg@bitbucket.org
says the ssh connection works fine! (so it should work!!!)
Then I post
[ui]
ssh = C:\cygwin\bin\ssh.exe
into mercurial.ini in TortoiseHg
And I post
[paths]
default = ssh://hg@bitbucket.org/myusername/personal
Into the hgrc file.
But then when I want to push TortoiseHg says to me:
remote: Permission denied (publickey).
no suitable response from remote hg
Seems to me something is missing here but what exactly?
Edit: I don't want to used TortoisePlink because it is SUPER SUPER SUPER SLOW! And https just cancels the connection after uploading several megabytes.
回答1:
You probably need to specify username and/or port number. My mercurial.ini work fine and it looks like this:
[ui]
ssh="C:\cygwin64\bin\ssh.exe" -p 22 -l john
where john is the username on the remote machine and 22 the ssh port number.
来源:https://stackoverflow.com/questions/13210329/using-cygwin-ssh-exe-in-tortoisehg-possible