windows 下批量删除git 分支

匿名 (未验证) 提交于 2019-12-03 00:10:02

删除筛选出来的分支,比如fixed

git branch -D @(git branch | select-string  "fixed" | Foreach {$_.Line.Trim()})

 

除了master分支,其他都删除

git branch -D @(git branch | select-string -NotMatch "fixed" | Foreach {$_.Line.Trim()})

更多请看:https://dev.to/koscheyscrag/git-how-to-delete-all-branches-except-master-2pi0

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!