本文介绍了我怎样才能让git-svn摆脱不再存在的远程分支?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有一种方便的方式让我的本地git仓库忘记已被删除的远程分支? git svn fetch
不会像我希望的那样重新同步所有内容。我的本地仓库使用标准svn仓库布局( git svn -s ...
)导入。
为什么
git remote
没有在我的git-svn repo上列出任何内容? 通过执行以下命令可以删除孤立的远程分支: git分支-d -r my_branch
rm -rf .git / svn / refs / remotes / my_branch
一次删除所有孤立分支,而不是一次一个,请参阅的答案。
Is there a handy way to get my local git repo to forget about remote branches that have been deleted? git svn fetch
doesn't "re-sync everything" like I hoped it might. My local repo was set up with using an import of the standard svn repo layout (git svn -s …
).
related: Why does git remote
not list anything on my git-svn repo?
解决方案
You can remove orphaned remote branches by executing the following commands:
git branch -d -r my_branch
rm -rf .git/svn/refs/remotes/my_branch
To remove all orphaned branches at once rather than one at a time, see the answer here.
这篇关于我怎样才能让git-svn摆脱不再存在的远程分支?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!