Skip to content

Commit b676246

Browse files
authored
Update sync-main.yml
1 parent dc9fdb5 commit b676246

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/sync-main.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ jobs:
4848
echo "::endgroup::"
4949
- name: Push sync branch
5050
run: |
51-
echo "$GITHUB_TOKEN" | gh auth login --with-token
5251
git push origin sync-main-pr --force
5352
# Ensure branch is visible to GitHub
5453
gh api repos/:owner/:repo/commits/$(git rev-parse HEAD) || {
@@ -60,11 +59,13 @@ jobs:
6059
echo "Branch not yet visible to GitHub — waiting a bit more"
6160
sleep 10
6261
}
62+
gh api repos/:owner/:repo/branches/sync-main-pr --jq .
63+
git ls-remote origin
6364
env:
65+
GH_TOKEN: ${{ secrets.WORKFLOW_TOKEN }}
6466
GITHUB_TOKEN: ${{ secrets.WORKFLOW_TOKEN }}
6567
- name: Create or update PR
6668
run: |
67-
echo "$GITHUB_TOKEN" | gh auth login --with-token
6869
git branch
6970
gh api repos/:owner/:repo/commits/$(git rev-parse HEAD) || {
7071
echo "Branch not yet visible to GitHub — waiting a bit more"
@@ -84,5 +85,6 @@ jobs:
8485
fi
8586
exit 0
8687
env:
88+
GH_TOKEN: ${{ secrets.WORKFLOW_TOKEN }}
8789
GITHUB_TOKEN: ${{ secrets.WORKFLOW_TOKEN }}
8890

0 commit comments

Comments
 (0)