hg git的权限被拒绝
我正试图从git repo中提取数据,并使用读写访问将其转换为mercurial,但我一直遇到以下错误:hg git的权限被拒绝,git,github,ssh,mercurial,Git,Github,Ssh,Mercurial,我正试图从git repo中提取数据,并使用读写访问将其转换为mercurial,但我一直遇到以下错误: hg clone git+ssh://github.com/user/myrepo.git destination directory: myrepo Permission denied (publickey). abort: git remote error: The remote server unexpectedly closed the connection. 根据的建议,我通过“
hg clone git+ssh://github.com/user/myrepo.git
destination directory: myrepo
Permission denied (publickey).
abort: git remote error: The remote server unexpectedly closed the connection.
根据的建议,我通过“git add github_rsa”将与我的git帐户相关联的私钥添加到,但没有任何效果。我在私人回购和将其改为公开回购两方面都尝试过。我还将所有必要的添加内容放入了.hgrc文件中。有人知道怎么解决这个问题吗 您需要使用
git@github.com
而不是github.com
,例如:hg clone git+ssh://git@github.com/user/myrepo
git add
与Mercurial | HGGit无关。您已经(除了使用正确的URL,如Reimer所述):1)在您的Github帐户中注册您的公钥2)根据服务器需求为已发布的私钥提供私钥证据(取决于操作系统,我无法预测您的情况)