我如何重命名git远程? [英] How do I rename a git remote?
本文介绍了我如何重命名git远程?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我目前有一个名为 heroku
的git remote,我想将它重命名为 production
。 p>
$ git remote -v
heroku https://git.heroku.com/example.git(fetch)
heroku https://git.heroku.com/example.git(push)
解决方案
$ git remote rename< old-name> <新名称>
因此,对于这个例子:
$ git remote rename heroku production
这里有用的文档: https://help.github.com/articles/renaming-a-remote/
I currently have a git remote called heroku
and I'd like to rename it to production
.
$ git remote -v
heroku https://git.heroku.com/example.git (fetch)
heroku https://git.heroku.com/example.git (push)
解决方案
$ git remote rename <old-name> <new-name>
So, for this example:
$ git remote rename heroku production
Useful docs here: https://help.github.com/articles/renaming-a-remote/
这篇关于我如何重命名git远程?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文