Thanks for your interest in contributing! This guide covers how to get started.
- Node.js >= 18
- npm
git clone https://github.com/UnityInFlow/spec-ci-plugin.git
cd spec-ci-plugin
npm installnpm run lint # Type check (tsc --noEmit)
npm test # Run all tests
npm run test:watch # Watch mode
npm run build # Produce dist/index.js (CJS bundle)
npm run format # Check formatting
npm run format:fix # Fix formatting- Fork the repo and create a feature branch from
main - Make your changes in
src/ - Add or update tests in
tests/ - Run
npm run lint && npm test && npm run buildto verify - Commit with a descriptive message following Conventional Commits:
feat: add new checker for Xfix: handle empty spec file in scope checkertest: add edge cases for criteria matcherdocs: update README with new input
- Open a PR against
main
src/
index.ts Action entry point (4-step pipeline)
types.ts Shared interfaces
spec-linter.ts Run spec-linter via npx
injection-scanner.ts Download + run injection-scanner binary
scope-checker.ts Extract scope from spec, compare to PR diff
criteria-checker.ts Parse test descriptions, match to criteria
comment-builder.ts Build markdown PR comment
github.ts Post/update PR comment via GitHub API
tests/
fixtures/ Test fixture files
*.test.ts Test files (one per module)
- TypeScript strict mode -- no
anytypes consteverywhere, named exports- Early returns over nested
ifblocks - Tests use vitest (
describe,it,expect)
Only maintainers can release. The process:
- Bump version in
package.json - Run
npm run buildand commitdist/ - Tag with
git tag vX.Y.Z - Push tag and create GitHub Release
By contributing, you agree that your contributions will be licensed under the MIT License.