Skip to content

Commit cb9409d

Browse files
committed
tools: generate config schema from option metadata
1 parent 058730d commit cb9409d

5 files changed

Lines changed: 58 additions & 1091 deletions

File tree

.github/workflows/linters.yml

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -283,21 +283,3 @@ jobs:
283283
- run: tools/lint-readme-lists.mjs "$TEAMS"
284284
env:
285285
TEAMS: ${{ tojson(steps.team_members.outputs) }}
286-
check-config-schema-sync:
287-
if: github.event.pull_request.draft == false
288-
runs-on: ubuntu-slim
289-
steps:
290-
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
291-
with:
292-
persist-credentials: false
293-
sparse-checkout: |
294-
/doc/node-config-schema.json
295-
/src/node_config_schema.h
296-
/tools/gen_node_config_schema.mjs
297-
sparse-checkout-cone-mode: false
298-
- name: Use Node.js ${{ env.NODE_VERSION }}
299-
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
300-
with:
301-
node-version: ${{ env.NODE_VERSION }}
302-
- name: Verify src/node_config_schema.h matches doc/node-config-schema.json
303-
run: node tools/gen_node_config_schema.mjs --check

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -863,7 +863,7 @@ doc: $(NODE_EXE) doc-only ## Build Node.js, and then build the documentation wit
863863

864864
out/doc:
865865
mkdir -p $@
866-
cp doc/node-config-schema.json $@
866+
$(NODE) tools/gen_node_config_schema.mjs --json-out $@/node-config-schema.json
867867

868868
# If it's a source tarball, doc/api already contains the generated docs.
869869
# Just copy everything under doc/api over.

0 commit comments

Comments
 (0)