feat: add config validation workflow and editor schema hints#286
feat: add config validation workflow and editor schema hints#286gildesmarais merged 6 commits intomasterfrom
Conversation
1fa9843 to
aaaf540
Compare
aaaf540 to
8a67725
Compare
There was a problem hiding this comment.
Pull request overview
This PR integrates config validation via html2rss validate into the CI pipeline and developer workflow, adds JSON schema support for editor autocompletion, and modernizes the build tooling. It adds schema modeline comments to all YAML config files, introduces a validate Make target, pins prettier as a local dependency, and bumps GitHub Actions versions.
Changes:
- Added
validateandschemaMake targets, abin/validate_configsRuby script, and a corresponding CI step; bumpedactions/checkoutandactions/setup-nodeto v4 - Added
yaml-language-serverschema modeline to all YAML config files underlib/html2rss/configs/, with VS Code settings and extension recommendations for editor integration - Introduced
package.json/package-lock.jsonwith prettier as a local npm devDependency, replacingnpxinvocations with the local binary path
Reviewed changes
Copilot reviewed 54 out of 58 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
.github/workflows/ruby.yml |
Bump action versions to v4; add npm ci and make validate steps |
Makefile |
Add validate/schema targets; add validate to default goal; switch prettier from npx to local binary; fix double-space |
bin/validate_configs |
New Ruby script to validate all YAML configs against html2rss schema |
bin/setup |
Modernize setup script: add npm install, system tool checks, and usage hints |
package.json / package-lock.json |
Pin prettier 3.8.1 as a local devDependency |
.gitignore |
Exclude generated /schema/ directory |
.vscode/settings.json / .vscode/extensions.json |
VS Code YAML schema association and extension recommendation |
README.md |
Add Validation and Editor Setup (JSON Schema) documentation sections |
lib/html2rss/configs/**/*.yml (47 files) |
Add schema modeline comment to all config files |
lib/html2rss/configs/espn.com/f1.yml |
Schema modeline added, but also contains suspicious strategy: default and s: 'dfd' additions |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| validate: | ||
| bundle exec ruby bin/validate_configs |
There was a problem hiding this comment.
The PR description says "drop obsolete migrate-tests/restore-tests targets whose backing script no longer exists," but these targets (lines 42-52) are still present in the Makefile. The bin/migrate_to_dynamic_tests script referenced by migrate-tests doesn't exist, so running make migrate-tests will fail. These targets should be removed as stated in the PR description.
Summary
bin/validate_configsworkflow and wiremake validateinto CI--ignore-scriptsCommit Stack
feat(devx): add config validation workflowfeat(config): add YAML schema hints for editorsfix(devx): pin prettier and harden config validationfix(ci): skip schema-only changed config fetch testsNotes
yaml-language-serverschema commentVerification
bundle exec ruby bin/validate_configsbundle exec rspecnpm ci --ignore-scripts --no-fund --no-audit./node_modules/.bin/prettier --check lib/**/*.yml .github/**/*.yml README.mdruby bin/rspec_changed_configs