We welcome contributions to the RDFormat Validator project! This document provides guidelines for contributing.
-
Fork and Clone
git clone https://github.com/your-username/rdformat-validator.git cd rdformat-validator -
Install Dependencies
npm install
-
Build the Project
npm run build
-
Run Tests
npm test
-
Create a Branch
git checkout -b feature/your-feature-name # or git checkout -b fix/your-bug-fix -
Make Changes
- Write your code following the existing style
- Add tests for new functionality
- Update documentation as needed
-
Test Your Changes
npm run validate:full # Runs type-check, lint, and tests npm run build # Ensure build works
-
Commit Your Changes We use Conventional Commits:
git commit -m "feat: add new validation rule for diagnostics" git commit -m "fix: handle empty source paths correctly" git commit -m "docs: update API documentation for validator"
-
Push and Create PR
git push origin your-branch-name
Then create a pull request from your fork.
We follow the Conventional Commits specification:
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
feat: A new featurefix: A bug fixdocs: Documentation only changesstyle: Changes that do not affect the meaning of the coderefactor: A code change that neither fixes a bug nor adds a featureperf: A code change that improves performancetest: Adding missing tests or correcting existing testsbuild: Changes that affect the build system or external dependenciesci: Changes to our CI configuration files and scriptschore: Other changes that don't modify src or test files
feat: add support for nested diagnostic validation
fix: handle malformed JSON gracefully
docs: add examples for CLI usage
test: add integration tests for fixer module- We use ESLint for code linting
- TypeScript strict mode is enabled
- Follow existing patterns in the codebase
- Write meaningful variable and function names
- Add JSDoc comments for public APIs
- Write unit tests for all new functionality
- Ensure existing tests continue to pass
- Add integration tests for complex features
- Test both success and error cases
test/
├── unit/ # Unit tests
├── integration/ # Integration tests
└── fixtures/ # Test data files
- Update README.md for new features
- Add JSDoc comments for public APIs
- Update CLI documentation in docs/CLI.md
- Add examples for new functionality
We use semantic-release for automated releases:
- Commits to
maintrigger automated releases - Version numbers follow Semantic Versioning
- CHANGELOG.md is automatically updated
- Packages are published to npm automatically
- Open an issue for bugs or feature requests
- Check existing issues before creating new ones
- Join discussions in existing issues
Thank you for contributing! 🎉