-
Notifications
You must be signed in to change notification settings - Fork 43
GitHub Actions: Warn if docs manifest possibly outdated #232
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
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## trunk #232 +/- ##
=======================================
Coverage ? 1.17%
Complexity ? 4416
=======================================
Files ? 261
Lines ? 27017
Branches ? 0
=======================================
Hits ? 318
Misses ? 26699
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| @@ -0,0 +1,40 @@ | |||
| name: Keep docs manifest up to date | |||
| on: | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The on config here is what diverges the most from the other workflows. Initially, based on Gutenberg's components-changelog workflow, I wanted this check to be more conservative.
But now that I look at it again, and given the approach I finally took, maybe it should be the same as in the others. Thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me like this. What do you think could be different?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wasn't sure about the preferences — if any — for the branches property, nor about which workflows should also run on push events. But I'm about to push a simplification here, limiting the workflow to pull_request events and looking more like other workflows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request events sound good, regenerating the manifest should be enforces for PRs that target trunk 👍
b98bd96 to
b4cbd29
Compare
b4cbd29 to
174afad
Compare
priethor
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love to see this!
| @@ -0,0 +1,40 @@ | |||
| name: Keep docs manifest up to date | |||
| on: | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me like this. What do you think could be different?
Feel free to close if useless!
Noticing the problem in #220, I drew inspiration from one of Gutenberg's workflows to add a workflow that will fail if
docs/bin/manifest.jsonneeds to be regenerated.It does this by running the
docs:manifestcomposer script and verifying that the manifest has not changed. If it has, something is wrong with the branch, and the developer is told to manually generate the docs. I prefered the manual approach for several reasons, one of which is to avoid "magic" and instead teaching/reminding the developer of processes.I attempted to fit into the style and practices of this repo's other workflows, but I may be wildly wrong. I'll also let you folks label this as you see fit. :)