Git
git delete multiple branch
Open the terminal, or equivalent.
Type in
git branch | grep "<pattern>"
for a preview of the branches that will be deleted.Type in
git branch | grep "<pattern>" | xargs git branch -D
git --diff-filter=d
example that only detect changed file that has .py
extention
useful script
—diff-filter=d 는 deleted를 제외한 결과를 가져다줌.
삭제한 파일을 grep하고 싶지 않아서 저게 꼭 필요한 옵션이었는데
해당 결과를 받으려면 아래처럼 입력해야함.
-diff-filter=ACMRTUXB
7글자 다 치는게 말이 안된다 생각해서 document 보니 소문자로 입력하면 exclude옵션으로 처리해줌.
해서 아래처럼 짰음.
아래는 완성된 스크립트중 일부.(일부임! 너무길어서 일부만 넣음)
submodule
after apply submodule on your repository, you must set root directory in you IDE
Last updated
Was this helpful?