[英]How can I make git-svn get rid of remote branches that don't exist anymore?
Is there a handy way to get my local git repo to forget about remote branches that have been deleted? 是否有一种方便的方法让我的本地git repo忘记已被删除的远程分支?
git svn fetch
doesn't "re-sync everything" like I hoped it might. git svn fetch
不像我希望的那样“重新同步一切”。 My local repo was set up with using an import of the standard svn repo layout ( git svn -s …
). 使用标准svn repo布局(
git svn -s …
)的导入设置了我的本地仓库。
related: Why does git remote
not list anything on my git-svn repo? 相关: 为什么
git remote
没有在我的git-svn repo上列出任何内容?
On the first thought, I would suggest trying git remote prune
. 在第一个想法,我会建议尝试
git remote prune
。 Excerpt from documentation : 摘自文档 :
prune
修剪
Deletes all stale remote-tracking branches under .
删除所有过时的远程跟踪分支。 These stale branches have already been removed from the remote repository referenced by , but are still locally available in "remotes/".
这些陈旧的分支已经从引用的远程存储库中删除,但仍然在“远程/”中本地可用。
With --dry-run option, report what branches will be pruned, but do not actually prune them.
使用--dry-run选项,报告将修剪哪些分支,但实际上不要修剪它们。
I think this should also work with a remote called svn
... 我认为这也适用于名为
svn
的遥控器...
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.