From 98370e687fe56ca9e9e7c73b70386c68b6596c3a Mon Sep 17 00:00:00 2001 From: Perry Werneck Date: Wed, 5 Feb 2020 18:17:03 -0300 Subject: [PATCH] Small adjustments in gitsync script. --- gitsync.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gitsync.sh b/gitsync.sh index 3d89d0a..524b09e 100755 --- a/gitsync.sh +++ b/gitsync.sh @@ -17,13 +17,14 @@ git push git fetch origin git merge +BRANCH=$(git symbolic-ref --short HEAD) REPOS=$(git remote -v | grep -v origin | grep "(push)" | awk '{print $1}') for repo in ${REPOS} do - echo "Getting updates from ${repo} ..." - git fetch ${repo} - git merge + echo "Getting updates to branch ${BRANCH} from ${repo} ..." + git fetch "${repo}" "${BRANCH}" +# git merge 2>&1 > /dev/null done for repo in ${REPOS} -- libgit2 0.21.2