首页 > 解决方案 > 远程:在 mac 终端中找不到存储库错误

问题描述

我是 git 新手。我有一个私人仓库,现在我想将本地仓库的更改推送到远程仓库。但是,我收到一个错误:

remote: Repository not found.
fatal: repository 'https://github.com/co-csp/csm.git/' not found

什么可能导致这些错误,请帮助我如何解决它,我正在使用Mac 终端。我的用户名是github 个人资料中的john2git config user.namegit config user.username两者都给出john2,所以用户名似乎正确......

标签: gitgithubgit-pushgit-remote

解决方案


如果您正在使用私有存储库,请执行以下操作:

  1. git 远程 rm 起源
  2. git 远程添加源 https://user@github.com/co-csp/csm.git
  3. git 克隆 https://user@github.com/co-csp/csm.git

这应该会提示您输入 GitHub 密码,并且应该如下所示。

克隆到“csm”...“https://user@github.com”的密码:


推荐阅读