Skip to content

Commit 5423da4

Browse files
authored
Merge pull request #5443 from miqui/contributing-local-validation
Clarify local validation commands in CONTRIBUTING.md
2 parents 8e166da + 0ee400f commit 5423da4

1 file changed

Lines changed: 12 additions & 5 deletions

File tree

CONTRIBUTING.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -179,16 +179,23 @@ Draft pull requests can still be reviewed while in draft state.
179179
> [!NOTE]
180180
> `npm run build-src` calls bash scripts. Use [Git Bash](https://gitforwindows.org/) on Windows, or use the Windows Subsystem for Linux (WSL).
181181
182-
The markdown source files are converted to HTML before publishing.
183-
To do this locally, please
182+
Before creating a pull request or marking a draft pull request as ready for review, validate your changes locally:
184183

185184
1. Install [Node.js](https://nodejs.org/)
186185
2. Check out this repo, go to the repo root, and switch to a development branch
187186
3. Execute `npm install` (once, repeat after merging upstream changes)
188-
4. Execute `npm run build-src` after changing `src/oas.md` (this first executes `npm run validate-markdown`, which can also be run separately)
189-
5. Open output file `deploy-preview/oas.html` with a browser and check your changes
187+
4. Run the commands relevant to what you changed:
190188

191-
Please make sure the markdown validates and builds using the above steps before creating a pull request or marking a draft pull request as ready for review.
189+
| Command | What it does |
190+
| ------- | ------------- |
191+
| `npm run validate-markdown` | markdownlint + link check only — fast loop while editing |
192+
| `npm run format-markdown` | auto-fix markdownlint violations |
193+
| `npm run build-src` | full check: validation, HTML build, schema publish |
194+
| `npm test` | runs the JSON Schema and build tooling test suites |
195+
196+
5. After `npm run build-src`, open output file `deploy-preview/oas.html` with a browser and check your changes
197+
198+
Please make sure the markdown validates and builds, and that `npm test` passes, before creating a pull request or marking a draft pull request as ready for review.
192199

193200
## Reviewers
194201

0 commit comments

Comments
 (0)