Skip to content

Server dummy patch 2 #1

Server dummy patch 2

Server dummy patch 2 #1

Workflow file for this run

name: PR Review
on:
pull_request:
branches: [master]
jobs:
review:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Check for template
run: |
# Replace "## Pull Request Template" with the actual template string
if echo "${{ github.event.pull_request.body }}" | grep "## Pull Request Template" > /dev/null; then
echo "Template found!"
else
echo "Error: PR template is missing!"
exit 1
fi
- name: Set draft status
if: always()
uses: actions/github-script@v6
with:
script: |
github.rest.issues.update({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
state: 'draft'
})
- name: Add bot-review label
if: always()
uses: actions/github-script@v6
with:
script: |
github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
labels: ['bot-review']
})
- name: Remove bot-review label
if: always()
uses: actions/github-script@v6
with:
script: |
github.rest.issues.removeLabel({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
name: 'bot-review'
})