From aec9d8b1a39cddb579df502e0c75fba1b7b0bf4e Mon Sep 17 00:00:00 2001 From: Ali Servet Donmez Date: Tue, 7 Jun 2016 09:32:41 +0200 Subject: [PATCH] Improve cleaning up branches merged into master --- tips.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tips.json b/tips.json index dfffb7a..727db1b 100644 --- a/tips.json +++ b/tips.json @@ -36,7 +36,7 @@ "tip": "git checkout -" }, { "title": "Remove branches that have already been merged with master", - "tip": "git branch --merged | grep -v '\\*' | xargs -n 1 git branch -d" + "tip": "git branch --merged master | grep -v '^\\*' | xargs --no-run-if-empty -n 1 git branch -d" }, { "title": "List all branches and their upstreams, as well as last commit on branch", "tip": "git branch -vv"