Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
E:\Windows\system32>heroku login
Enter your Heroku credentials.
Email: mymail@yahoo.com
Password (typing will be hidden):
Found existing public key: E:/Users/Stewie/.ssh/id_rsa.pub
Uploading SSH public key E:/Users/Stewie/.ssh/id_rsa.pub... failed
! Fingerprint already exists. Please use one SSH key per Heroku account
E:\Windows\system32>git clone git@heroku.com:sharp-winter-5732.git -o heroku
Cloning into 'sharp-winter-5732'...
! Your key with fingerprint f2:a2:f9:4a:c4:16:5b:f1:5a:21:cb:d8:c4:d2:18:ef is
not authorized to access sharp-winter-5732.
fatal: The remote end hung up unexpectedly
E:\Windows\system32>
为什么我一直有这个错误?我该怎么办?并且不要给我一个减号,因为我已经看过了
https://help.github.com/articles/set-up-git
并给我
E:\Windows\system32>git config --global user.name "Stewie"
E:\Windows\system32>git config --global user.email "mymail@yahoo.com"
E:\Windows\system32>git config --global credential.helper cache
warning: credential.helper has multiple values
error: cannot overwrite multiple values with a single value
Use a regexp, --add or --replace-all to change credential.helper.
E:\Windows\system32>git config --global credential.helper 'cache --timeout=3600'
E:\Windows\system32>git clone git@heroku.com:sharp-winter-5732.git -o heroku
Cloning into 'sharp-winter-5732'...
! Your key with fingerprint f2:a2:f9:4a:c4:16:5b:f1:5a:21:cb:d8:c4:d2:18:ef is
not authorized to access sharp-winter-5732.
fatal: The remote end hung up unexpectedly
E:\Windows\system32>
我也试过
GitHub: Permission denied (publickey). fatal: The remote end hung up unexpectedly
我不知道该怎么做......
答案 0 :(得分:29)
您的钥匙似乎有问题。也许您需要将当前密钥上传到heroku
heroku keys:add
详细信息"管理您的SSH密钥":https://devcenter.heroku.com/articles/keys
答案 1 :(得分:0)
Permission denied (publickey) when deploying heroku code. fatal: The remote end hung up unexpectedly
在此链接中,我遇到了同样的问题,以下步骤对我有用:
->heroku login
abc@gmail.com & password
->cd C:\Users\yourusername\.ssh
->ssh-keygen -t rsa -f id_rsa
如果要求任何密码不要使用空白,请填写密码,但不要忘记密码。
->heroku keys:add "id_rsa.pub"
将目录更改为工作区,然后
->git clone git@heroku.com:stark-dawn-1234.git -o heroku
使用您在上面设置的密码。