我目前正在將我的文件從Windows遷移到Mac。其中之一就是我的所有git倉庫。我在Windows上做的是我有我的.ppk和從PuttyGen生成的公鑰,然後使用Pageant在從git repo克隆的同時添加.ppk文件。我在Windows中使用GitExtension。無法在Windows上使用我的私鑰在Windows上工作克隆
現在在Mac上,我創建了一個本地repo文件夾,其中將存儲所有克隆的repo。把我的公鑰和私鑰放到〜/ .ssh /中。和編輯的〜/ .ssh/config並添加這樣的:
Host 192.168.20.4
User git
HostName 192.168.20.4
IdentityFile ~/.ssh/user_git.ppk
我在想,一切都成立,但仍即時得到一個:
MACBOOKs-MacBook-Pro:.ssh username$ git clone
[email protected]:repositories/project-repo.git
Cloning into 'project-repo'...
Enter passphrase for key '/Users/username/.ssh/user_git.ppk':
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:
Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
每次我從窗戶與克隆私鑰,它不會要求密碼或密碼。
我也用GitKraken和使用的PRIVATE_KEY有,但仍拒絕權限
我已經複製從Windows到Mac多時間的密鑰,但仍無法在所有工作。
什麼設置仍然失蹤?
謝謝!
我只是跟着從你的鏈接教程,並使用在〜/ .ssh/config中的私鑰。現在它的工作!感謝:D –