Fix GitHub Actions permissions for pushing to main
Use explicit GitHub token for authentication when pushing to main branch in the
queue-main workflow to resolve the 403 permission denied error.
Co-Authored-By: sketch <hello@sketch.dev>
diff --git a/.github/workflows/queue-main.yml b/.github/workflows/queue-main.yml
index c86cd87..ae4bfe2 100644
--- a/.github/workflows/queue-main.yml
+++ b/.github/workflows/queue-main.yml
@@ -46,4 +46,6 @@
run: |
git config --global user.name "GitHub Actions Bot"
git config --global user.email "actions@github.com"
- git push origin HEAD:main
+ git push https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@github.com/boldsoftware/sketch.git HEAD:main
+ env:
+ GITHUB_TOKEN: ${{ github.token }}