Skip to content

Commit

Permalink
updated pr policy checker with gh pr
Browse files Browse the repository at this point in the history
Signed-off-by: mojafa <[email protected]>
  • Loading branch information
mojafa committed Jan 31, 2025
1 parent 2c6cbf2 commit 2037964
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/content-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on: [pull_request]

permissions:
pull-requests: write
contents: read
issues: write

jobs:
content-compliance:
Expand Down Expand Up @@ -55,9 +57,8 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl -X POST -H "Authorization: Bearer $GITHUB_TOKEN" -H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/comments \
-d '{"body": "Hi @${{ github.event.pull_request.user.login }}, our policy allows contributors to work on one issue at a time. Please complete or close your existing pull requests before creating a new one."}'
gh pr comment ${{ github.event.pull_request.number }} \
--body "Hi @${{ github.event.pull_request.user.login }}, our policy allows contributors to work on one issue at a time. Please complete or close your existing pull requests before creating a new one."
exit 1
- name: File Naming and Folder Structure Compliance
Expand Down

0 comments on commit 2037964

Please sign in to comment.