From 4a323ad988182bb940c048aadd103e7cf8089186 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 8 Mar 2023 08:17:11 +0100 Subject: Also calling pull the current branch in git-pull-branches. Signed-off-by: Daniel Baumann --- git/bin/git-pull-branches | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'git') diff --git a/git/bin/git-pull-branches b/git/bin/git-pull-branches index 9effa17..afa2e63 100755 --- a/git/bin/git-pull-branches +++ b/git/bin/git-pull-branches @@ -24,6 +24,10 @@ set -e CURRENT_BRANCH="$(git branch --show-current)" REMOTE_BRANCHES="$(git branch -r | awk '{ print $1 }')" +# pull current branch +git pull + +# pull remote branches for REMOTE_BRANCH in ${REMOTE_BRANCHES} do BRANCH="$(echo "${REMOTE_BRANCH}" | cut -d/ -f 2-)" @@ -43,6 +47,7 @@ do fi done +# checkout current branch if [ "$(git branch --show-current)" != "${CURRENT_BRANCH}" ] then git checkout "${CURRENT_BRANCH}" -- cgit v1.2.3