Skip to content

chore: add documentation reminder issue tracker #256

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

Merged
merged 23 commits into from
Feb 8, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions .github/workflows/missing-documentation-reminder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Missing Documentation Reminder

on:
workflow_dispatch:
pull_request:
types:
- edited
- closed

jobs:
find-missing-documentation:
permissions:
contents: read
pull-requests: read
issues: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Find closed PRs with 'needs documentation' label
uses: actions/github-script@v6
id: find-prs
with:
script: |

const query = `repo:makspll/bevy_mod_scripting is:pr is:merged is:closed label:"needs documentation"`;
const encodedQuery = encodeURIComponent(query);

console.log(encodedQuery);

const { data: { items: pullRequests } } = await github.rest.search.issuesAndPullRequests({
q: query,
per_page: 1
});

console.log(pullRequests)

const prsNeedingDocs = pullRequests.map(pr => `- [ ] ${pr.html_url} by @${pr.user.login}`).join("\n");
if (!prsNeedingDocs) {
return "- [x] All PRs with 'needs documentation' label have been updated in the book.";
} else {
return prsNeedingDocs;
}
result-encoding: string

- name: Update Issue Body
uses: julien-deramond/update-issue-body@v1
with:
issue-number: 255
body: |
This is an automatically generated issue.

The following PRs have been closed but still need updates in the book:
${{ steps.find-prs.outputs.result }}

If you are an author of one of these PRs, please consider updating the boook in `/docs` with appropriate documentation.
Thank you!
edit-mode: replace
Loading