无法访问私有github repo(我有公钥和私钥)

无法访问私有github repo(我有公钥和私钥),github,ssh,ssh-keys,Github,Ssh,Ssh Keys,我需要访问(克隆)GitHub上的私有存储库,该存储库属于我无法与之通信的开发人员。我已经获得了公钥和私钥(我猜它们可能是特定存储库的部署密钥?) 运行以下终端命令后: git clone git@github.com:theirusername/reponame.git 我收到以下错误: Cloning into 'reponame'... ERROR: Repository not found. fatal: Could not read from remote repository.

我需要访问(克隆)GitHub上的私有存储库,该存储库属于我无法与之通信的开发人员。我已经获得了公钥和私钥(我猜它们可能是特定存储库的部署密钥?)

运行以下终端命令后:

git clone git@github.com:theirusername/reponame.git
我收到以下错误:

Cloning into 'reponame'...
ERROR: Repository not found.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
开发人员还在自述文件中包含以下注释和密钥: 开发人员说明(将敏感信息替换为“x”)

我已经尝试将公钥添加到我的Github帐户(在设置-->SSH和GPG密钥下)。这似乎无助于解决这个问题


我确信这里有一些基本的东西我没有掌握。我是否需要公钥和私钥才能访问回购协议?如果是,我必须在哪里登记?非常感谢您的帮助。

您需要在家中存储公钥和私钥(
~/.ssh

然后可以使用
ssh-T测试连接git@github.com
:如果这些密钥来自其他开发人员,则应显示一条带有其他开发人员姓名的欢迎消息(因为公钥应在其GitHub帐户下注册)

如果您有多个密钥,则需要一个
~/.ssh/config文件

===============
"This SSH public/private keypair allows full access to the server.
DO NOT GIVE THESE FILES TO ANYONE THAT YOU DON'T WANT ACCESSING YOUR ENTIRE SERVER AND ASSOCIATED SERVICES.

- The SSH port is XXXXX.
- There is no passphrase on the keys.
- The keys allow access to two users: `xxx` (standard privs) and `xxx` (for sudo and su-ing to root)
- These keys also allow access to the GitHub repository: github.com/theirusername/reponame.git"