From aa3ac21ee9f252eb144cb558c295666431baf788 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Fri, 27 Aug 2021 11:36:27 +0100 Subject: Helper to find branches with bugs (b) and feature (f) prefixes --- bashrc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'bashrc') diff --git a/bashrc b/bashrc index 65890e4..87a2343 100644 --- a/bashrc +++ b/bashrc @@ -273,6 +273,9 @@ gppdmb() { PARENT=${1:-master} git checkout $PARENT && git pull --prune && git delete-merged-branches } +findbranches() { + find ~/work/ -name .git -type d | while read r ; do echo $r ; git -C $(dirname $r) branch -a | grep "\<.$1[^0-9]" ; done +} createAllBranches() { for branch in $(git branch --all | grep '^\s*remotes' | egrep --invert-match '(:?HEAD|master)$'); do git branch --track "${branch#*/*/}" "$branch"; done } -- cgit v1.2.3