无法移除远程原点 [英] Cannot remove remote origin
本文介绍了无法移除远程原点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在OS X上运行git 1.8.0,并且每个新的git仓库似乎都有一个名为origin的远程设备:
I'm running git 1.8.0 on OS X, and every new git repo seems to have a remote called "origin":
$ git init
$ git remote
origin
奇怪的是是我不能删除它:
What's odd is that I can't remove it:
$ git remote remove origin
error: Could not remove config section 'remote.origin'
因此我无法添加名为原点
。为什么是这样?我可以做些什么来改变它?
And therefore I can't add a new remote called origin
. Why is this? What can I do to change it?
推荐答案
您应该能够移除 origin
You should be able to remove origin
with
git remote rm origin
不是你需要的,你可以用 set-url $ c>来改变
origin
$ b
Not that you need to, you can just change the origin
with set-url
git remote set-url origin "https://..."
这篇关于无法移除远程原点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文