-
Notifications
You must be signed in to change notification settings - Fork 447
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add: GitHub actions, check that reviewer has commented on PR + tag do…
…cs PRs (#3788) * Create docs-check.yml * Update docs-check.yml * Update docs-check.yml * Create docs-tag.yml
- Loading branch information
1 parent
9c67472
commit 4217147
Showing
2 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Validate Docs PR comments | ||
on: | ||
issue_comment: | ||
types: [created] | ||
paths: | ||
- docs/developer-docs/ | ||
|
||
jobs: | ||
check_comment: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
- uses: actions/github-script@v6 | ||
if: contains(github.event.comment.body, 'I agree that I have run the commands and code included in this PR and have confirmed their accuracy and functionality.') | ||
with: | ||
script: | | ||
const comments = require('./.github/workflows/scripts/comments.js'); | ||
await comments.create(context, github, `PR content has been validated by a reviewer.`); | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Tag Docs PRs | ||
on: | ||
pull_request: | ||
paths: | ||
- docs/developer-docs/** | ||
jobs: | ||
docs-tag: | ||
name: Tag PR with documentation | ||
if: ${{ github.event_name == 'pull_request' }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
- name: Tag PR with documentation | ||
run: | | ||
gh pr edit ${{ github.event.pull_request.number }} --add-label documentation | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |