Skip to content

Commit

Permalink
Add PAT for Protected Branch Push Access (smithmicro#93)
Browse files Browse the repository at this point in the history
- Use `persist-credentials: false`, "... otherwise, the token used is the GITHUB_TOKEN, instead of your personal access token" (from https://github.com/ad-m/github-push-action#readme)
- Always fetch latest `default` branch before publishing pre-release
  • Loading branch information
mblomdahl committed Oct 23, 2022
1 parent 36d9792 commit d4b8575
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/publish-prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ jobs:
contents: write
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
fetch-depth: 0
ref: issue-93-gh-actions
- uses: actions/setup-node@v3
with:
node-version: 16
Expand Down Expand Up @@ -63,4 +67,4 @@ jobs:
uses: ad-m/github-push-action@master
with:
branch: master
github_token: ${{ secrets.GITHUB_TOKEN }}
github_token: ${{ secrets.GHA_MAPBOXGLCIRCLE_GITHUB_TOKEN }}
3 changes: 2 additions & 1 deletion .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
fetch-depth: 0
ref: master
- uses: actions/setup-node@v3
Expand Down Expand Up @@ -62,4 +63,4 @@ jobs:
uses: ad-m/github-push-action@master
with:
branch: master
github_token: ${{ secrets.GITHUB_TOKEN }}
github_token: ${{ secrets.GHA_MAPBOXGLCIRCLE_GITHUB_TOKEN }}

0 comments on commit d4b8575

Please sign in to comment.