diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2024-03-09 20:27:41 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2024-03-09 20:27:41 +1100 |
commit | 6bc85e6a2100e503fb241141b0dbc3e0d62bf58b (patch) | |
tree | b63ff5bb62f5a9fd091b988f0baba37c170ba388 | |
parent | 271ca555122fc1d6db00915a16b123e1ca6d4401 (diff) |
Test
-rw-r--r-- | .github/workflows/sponsors.yml | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/.github/workflows/sponsors.yml b/.github/workflows/sponsors.yml index 10906950c..79290f854 100644 --- a/.github/workflows/sponsors.yml +++ b/.github/workflows/sponsors.yml @@ -1,15 +1,24 @@ -# see https://github.com/JamesIves/github-sponsors-readme-action name: Generate Sponsors README on: push: branches: - master + pull_request: # Add this if you want to run checks on PRs as well + branches: + - master jobs: deploy: runs-on: ubuntu-latest steps: - name: Checkout 🛎️ uses: actions/checkout@v3 + with: + ref: master # This ensures the checkout step fetches the master branch + + - name: Switch to master branch + run: | + git fetch origin master:refs/remotes/origin/master + git checkout master - name: Generate Sponsors 💖 uses: JamesIves/github-sponsors-readme-action@v1.2.2 @@ -25,6 +34,6 @@ jobs: git config --global user.name "README-bot" git add README.md git commit -m "Updated README.md" || exit 0 - git push + git push origin master # Explicitly push to master branch env: - GITHUB_TOKEN: ${{secrets.GITHUB_API_TOKEN}} + GITHUB_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} |