我在git Bash中写了这个
git remote -v
origin git://github.com/devRena/test (fetch)
origin git://github.com/devRena/test (push)
Run Code Online (Sandbox Code Playgroud)
当我说
git push origin master
fatal remote error:
You can't push to git://github.com/devRena/test.git
Use https://github.com/devRena/test.git
Run Code Online (Sandbox Code Playgroud)
如何将git://github.com/devRena/test.git更改为 https://github.com/devRena/test.git ?
检查从GitHub 更改遥控器的URL文档:
使用以下git remote set-url命令更改遥控器的URL :
git remote set-url origin https://github.com/USERNAME/REPOSITORY.git
Run Code Online (Sandbox Code Playgroud)
在您的情况下,请尝试以下操作:
git remote set-url origin https://github.com/devRena/test.git
Run Code Online (Sandbox Code Playgroud)
您可以简单地手动编辑 .git/config 文件。
找到以下开头的部分:
[remote "origin"]
Run Code Online (Sandbox Code Playgroud)
代替:
url = https://github.com/USERNAME/REPOSITORY.git
Run Code Online (Sandbox Code Playgroud)
和
url https://github.com/devRena/test.git
Run Code Online (Sandbox Code Playgroud)
节省
| 归档时间: |
|
| 查看次数: |
6600 次 |
| 最近记录: |