小编Stu*_*ike的帖子

'git remote add' 不创建 repo

我想从我的 shell 添加远程存储库但失败了。我已登录并在我的本地存储库中。所以我输入这个:

% git remote add origin https://github.com/<username>/example.git
% git remote -v
origin  https://github.com/<username>/example.git (fetch)
origin  https://github.com/<username>/example.git (push)
Run Code Online (Sandbox Code Playgroud)

所以似乎已经创建了repo。但是我在我的 github 帐户中没有看到新的 repo。当我尝试检查遥控器(或在那里推送任何东西)时,它会引发错误:

% git remote show origin
remote: Repository not found.
fatal: repository 'https://github.com/<username>/example.git/' not found
Run Code Online (Sandbox Code Playgroud)

我尝试谷歌搜索类似的问题,但找不到答案。有谁知道我可能会错过什么?

git github git-remote

2
推荐指数
1
解决办法
112
查看次数

标签 统计

git ×1

git-remote ×1

github ×1