Thank you for your interest in contributing to CodeSync! This document provides guidelines and information for contributors.
- Node.js 18+
- PostgreSQL 15+
- Redis 7+
- Docker and Docker Compose
- Git
-
Fork and clone the repository
git clone https://github.com/your-username/CodeSync.git cd CodeSync -
Install dependencies
npm install
-
Set up environment variables
cp .env.example .env cp client/.env.example client/.env
-
Start development environment
docker-compose up -d cd server && npm run db:migrate && npm run db:seed cd .. && npm run dev
- Use TypeScript for all new code
- Follow ESLint and Prettier configurations
- Write meaningful commit messages
- Add tests for new features
- Update documentation as needed
type(scope): description
[optional body]
[optional footer]
Types:
feat: New featurefix: Bug fixdocs: Documentation changesstyle: Code style changesrefactor: Code refactoringtest: Adding or updating testschore: Maintenance tasks
feature/description- New featuresfix/description- Bug fixesdocs/description- Documentation updatesrefactor/description- Code refactoring
# Backend tests
cd server && npm test
# Frontend tests
cd client && npm test
# Load tests
cd server && npm run load-test- All new features must include tests
- Maintain or improve test coverage
- Tests should be meaningful and test actual functionality
- Include both positive and negative test cases
-
Create a feature branch
git checkout -b feature/your-feature-name
-
Make your changes
- Write clean, documented code
- Add tests for new functionality
- Update documentation if needed
-
Test your changes
npm test npm run lint -
Commit your changes
git add . git commit -m "feat: add new feature description"
-
Push to your fork
git push origin feature/your-feature-name
-
Create a Pull Request
- Use a clear title and description
- Reference any related issues
- Include screenshots for UI changes
- Ensure all checks pass
- Code follows project style guidelines
- Tests pass locally
- New tests added for new functionality
- Documentation updated if needed
- No breaking changes (or clearly documented)
- Commit messages follow convention
When reporting bugs, please include:
- Clear description of the issue
- Steps to reproduce
- Expected vs actual behavior
- Environment details (OS, Node version, etc.)
- Screenshots or logs if applicable
Use the bug report template when creating issues.
For feature requests, please:
- Check if the feature already exists
- Provide clear use case and rationale
- Consider implementation complexity
- Be open to discussion and feedback
- Follow RESTful API conventions
- Use proper HTTP status codes
- Implement proper error handling
- Add input validation
- Write comprehensive tests
- Use React functional components with hooks
- Implement proper state management with Zustand
- Follow responsive design principles
- Add proper error boundaries
- Write component tests
- Use Socket.IO for WebSocket communication
- Implement proper event handling
- Add connection state management
- Handle network failures gracefully
- Be respectful and inclusive
- Provide constructive feedback
- Help others learn and grow
- Follow project guidelines
- Report inappropriate behavior
- Create an issue for bugs or questions
- Join discussions in existing issues
- Check documentation first
- Be patient and respectful
Contributors will be recognized in:
- README.md contributors section
- Release notes for significant contributions
- Project documentation
Thank you for contributing to CodeSync! 🚀