Skip to content

[TEST] Another PR to test the auto-draft conversion #1

[TEST] Another PR to test the auto-draft conversion

[TEST] Another PR to test the auto-draft conversion #1

name: 'NEW: Post Draft PR Notice'
on:
pull_request:
types: [opened, ready_for_review, converted_to_draft]
jobs:
post-draft-notice:
name: Post Draft Notice
runs-on: ubuntu-latest
if: ${{ !github.event.pull_request.draft }}
steps:
- name: Print PR data payload
run: jq -n '${{ toJson(github.event.pull_request) }}'
- name: Post notification to non-draft PR
if: ${{ !github.event.pull_request.draft }}
run: |
curl -X POST \
-H "Authorization: Bearer ${{ secrets.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": "Hello, and thank you for contributing!\n\nThis project is configured to run fewer workflows on draft PRs, so if you would like to receive pass/fail feedback from the test suite more quickly, please switch this PR to '"'"'draft'"'"' status.\n\nYou can mark the PR as '"'"'ready'"'"' whenever you like, to enable the more extensive set of checks."}'