Skip to content

Commit 32f5a76

Browse files
authored
fix: add logging
1 parent 5e86432 commit 32f5a76

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

github-sync.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,20 @@ echo "UPSTREAM_REPO=$UPSTREAM_REPO"
2424
echo "BRANCHES=$BRANCH_MAPPING"
2525

2626
git config --unset-all http."https://github.com/".extraheader || :
27+
28+
echo "Resetting origin to: https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$GITHUB_REPOSITORY"
2729
git remote set-url origin "https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$GITHUB_REPOSITORY"
30+
31+
echo "Adding tmp_upstream $UPSTREAM_REPO"
2832
git remote add tmp_upstream "$UPSTREAM_REPO"
33+
34+
echo "Fetching tmp_upstream"
2935
git fetch tmp_upstream
3036
git remote --verbose
37+
38+
echo "Pushing changings from tmp_upstream to origin"
3139
git push origin "refs/remotes/tmp_upstream/${BRANCH_MAPPING%%:*}:refs/heads/${BRANCH_MAPPING#*:}" --force
40+
41+
echo "Removing tmp_upstream"
3242
git remote rm tmp_upstream
3343
git remote --verbose

0 commit comments

Comments
 (0)