feat(ci): Ensure that the README.md is in sync with internal/readme #53
+51
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation and Context
In this project the
README.md
is generated by runningmake
insideinternal/readme/
. The goal of this is to ensure that the code snippets that are used within theREADME.md
are kept in sync with the current state of the repo. In order to do this, we useweave
to combine the code snippets from standalone files into the final top levelREADME.md
file.Unfortunately, at the moment, it's extremely easy for folks to just update the README.md to fix / tweak various prose or code snippets which leaves things in a bad state. In that scenario the next "re-generation" would clobber any of the tweaks that were made manually to the top level
README.md
.Fixes #48
How Has This Been Tested?
Local testing of the script.
Breaking Changes
N/A -- This is a CI only change.
Types of changes
Checklist
Additional context
With these changes, any proposed PRs that edit either the top level
README.md
orinternal/readme/README.src.md
in such a way that the two files are no longer in sync (after re-runningweave
) will have a failing CI job that instructs folks to runmake
in theinternal/readme/
directory. PRs that do not touchinternal/readme/**
orREADME.md
in the project root will have no additional CI job.Additionally, I've added a section to the
CONTRIBUTING.md
that explains how to make changes to theREADME.md
.