-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't create contributors file #4
Comments
@samuelfernandez check the branch protection rules of your repository. I had almost the same issue, when I created a branch protection rule. I think the right way to fix is using permissions inside the workflow. |
@jrson83 Thanks for the reply. Any example of the permissions configuration? Or would you know which one exactly is needed? |
@samuelfernandez give me a minute, I just saw my workflow failed again. I will reply when I know how to fix it 😁 |
hmm I don't know. This action just uses commit and has just one option
The only rule I have set is |
@samuelfernandez I got it working by setting the option name: Contributors List
on:
workflow_dispatch:
schedule:
- cron: "0 3 */2 * *"
jobs:
contributors:
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 # v3.5.0
with:
fetch-depth: 0
ref: ${{ github.event.repository.default_branch }}
- name: Update contributors list
uses: wow-actions/contributors-list@b9e91f91a51a55460fdcae64daad0cb8122cdd53 # v1.1.0
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
svgPath: .github/assets/CONTRIBUTORS.svg
round: true
includeBots: false
noCommit: true
- name: Commit & PR
uses: peter-evans/create-pull-request@38e0b6e68b4c852a5500a94740f0e535e0d7ba54 # v4.2.4
with:
token: ${{ secrets.GITHUB_TOKEN }}
add-paths: .github/assets/CONTRIBUTORS.svg
commit-message: 'chore(): update contributors-list'
committer: GitHub <[email protected]>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
signoff: false
branch: workflow/update-contributors-list
base: main
delete-branch: true
title: 'chore(): update contributors-list'
body: |
Automated update to `.github/assets/CONTRIBUTORS.svg` |
Expected Behavior
It creates the svg file in the repo
Current Behavior
The creation of the contributors svg fails
Steps To Reproduce
https://github.com/ng-easy/platform/runs/7371097328?check_suite_focus=true
Error Message & Stack Trace
Additional Context
Your Environment
GitHub workflow
The text was updated successfully, but these errors were encountered: