Thank you for your interest in contributing to lcode! This document provides guidelines and information for contributors.
-
Clone the repository
git clone https://github.com/rkristelijn/lcode.git cd lcode -
Install dependencies
npm install
-
Run tests
npm test -
Run linter
npm run lint
lcode/
├── index.mjs # Main CLI entry point
├── src/
│ ├── utils.mjs # Utility functions
│ └── cache.mjs # Caching functionality
├── test/
│ ├── utils.test.mjs # Unit tests
│ ├── cache.test.mjs # Cache tests
│ └── integration.test.mjs # CLI integration tests
├── .github/workflows/ # CI/CD configuration
└── docs/ # Documentation
- ES2022+ JavaScript with ES modules
- ESLint for code linting
- Node.js built-in test runner for testing
- 100% test coverage for new features
- Semantic versioning for releases
We maintain comprehensive test coverage:
- Unit tests: Test individual functions in isolation
- Integration tests: Test CLI behavior end-to-end
- Manual testing: Verify real-world usage scenarios
Run tests with:
npm test # Run all tests
npm run test:watch # Watch mode for development-
Fork the repository
-
Create a feature branch
git checkout -b feature/your-feature-name
-
Make your changes
- Write tests for new functionality
- Update documentation if needed
- Follow existing code style
-
Run quality checks
npm test npm run lint -
Commit your changes
git commit -m "feat: add your feature description" -
Push and create a Pull Request
We follow conventional commits:
feat:New featuresfix:Bug fixesdocs:Documentation changestest:Test additions/changesrefactor:Code refactoringperf:Performance improvements
Before implementing new features:
- Check existing issues and discussions
- Create an issue to discuss the feature
- Wait for maintainer feedback
- Implement with tests and documentation
When reporting bugs:
- Use the issue template
- Provide reproduction steps
- Include system information
- Add relevant error messages
- Use ESLint configuration provided
- Prefer
constoverlet, avoidvar - Use descriptive variable names
- Add JSDoc comments for public functions
- Keep functions small and focused
- Use async operations where possible
- Implement caching for expensive operations
- Avoid blocking the event loop
- Profile performance-critical code
- Update README.md for user-facing changes
- Add JSDoc comments for new functions
- Include examples in documentation
- Update help text for CLI changes
Releases are handled by maintainers:
- Version bump following semver
- Update CHANGELOG.md
- Create GitHub release
- Publish to npm
- Check existing issues and discussions
- Ask questions in GitHub Discussions
- Join our community chat (if available)
- Contact maintainers directly for urgent issues
By contributing, you agree that your contributions will be licensed under the same ISC license as the project.