Welcome Contributors
Contributions to Timo are welcome! Whether you’re fixing bugs, adding features, improving documentation, or suggesting enhancements, your help is appreciated.Getting Started
Before you begin contributing, please:- Read through this contributing guide
- Review the architecture documentation to understand the codebase
- Check existing issues and pull requests to avoid duplicate work
- Join the discussion on GitHub to coordinate with other contributors
Repository Information
GitHub Repository
Fork and clone the repository to get started
Development Workflow
Create a Feature Branch
Create a new branch for your changes:Use descriptive branch names:
feature/add-reminder-supportfor new featuresfix/search-case-sensitivityfor bug fixesdocs/update-readmefor documentationrefactor/simplify-storage-layerfor refactoring
Make Your Changes
Implement your changes following the code style guidelines below. Ensure your changes:
- Are focused and solve a specific problem
- Don’t break existing functionality
- Follow the existing architecture patterns
- Include appropriate error handling
Test Your Changes
Build and test the application locally:Verify that:
- The application compiles without errors
- Your changes work as expected
- Existing commands still function correctly
Commit Your Changes
Write clear, descriptive commit messages:Good commit message format:
- Use present tense (“Add feature” not “Added feature”)
- Be concise but descriptive
- Reference issue numbers when applicable (“Fix #42: Search bug”)
Code Style Guidelines
Rust Best Practices
Follow standard Rust conventions:- Run
cargo fmtbefore committing to ensure consistent formatting - Run
cargo clippyto catch common mistakes and improve code quality - Use meaningful variable and function names
- Add documentation comments for public APIs
- Keep functions focused and reasonably sized
Project-Specific Patterns
Storage Layer
Storage Layer
When adding storage functionality:
- Add method to the
Storagetrait insrc/storage.rs - Implement in
SqliteStorageinsrc/sqlite/sqlite_storage.rs - Use parameterized queries to prevent SQL injection
- Handle database errors appropriately
Commands
Commands
When adding new commands:
- Add variant to
Commandsenum insrc/commands.rs - Include help text using clap’s
#[command(about = "...")] - Add match arm in
Executor::run()insrc/executor.rs - Implement business logic in
TaskService
Database Changes
Database Changes
When modifying the database schema:
- Create a new migration file in
src/sql_migrations/ - Follow naming convention:
V{N}__{description}.sql - Test migration both on new and existing databases
- Update Task model if adding/removing fields
Error Handling
The current codebase uses.unwrap() for simplicity, but consider:
- Using
Result<T, E>for operations that can fail - Providing helpful error messages to users
- Logging errors for debugging purposes
- Gracefully handling expected failure cases
Types of Contributions
Bug Fixes
Reporting Bugs
Found a bug? Please open an issue on GitHub with:
- Clear description of the problem
- Steps to reproduce
- Expected vs actual behavior
- Your environment (OS, Rust version)
- Reference the issue number in your PR
- Include details on what caused the bug
- Test edge cases to ensure the fix is complete
New Features
Feature Requests
Have an idea? Open an issue to discuss before implementing:
- Describe the feature and its use case
- Explain how it fits with Timo’s goals
- Consider alternative approaches
- Get feedback from maintainers
- Labels: ✅ Completed
- Clear Confirmation: ✅ Completed
- Reminders: 📅 Planned
Documentation
Documentation improvements are always welcome:- Fix typos or unclear explanations
- Add examples or use cases
- Improve code comments
- Update README or guides
- Write tutorials or blog posts
Code Quality
Help improve the codebase:- Refactor for clarity or performance
- Add error handling
- Improve test coverage
- Update dependencies
- Optimize algorithms or queries
Pull Request Guidelines
Before Submitting
- Code compiles without errors
- Changes are tested manually
- Code follows Rust formatting (
cargo fmt) - No clippy warnings (
cargo clippy) - Commit messages are clear and descriptive
- PR description explains the changes
PR Review Process
- Maintainers will review your PR
- You may receive feedback or change requests
- Address feedback by pushing new commits
- Once approved, your PR will be merged
Tips for Faster Review
- Keep PRs focused on a single change
- Provide context in the description
- Respond promptly to feedback
- Be open to suggestions
- Test thoroughly before submitting
Code of Conduct
Our Standards
We are committed to providing a welcoming and inclusive environment:- Be respectful: Treat everyone with respect and courtesy
- Be collaborative: Work together and help each other
- Be open-minded: Accept constructive criticism gracefully
- Be professional: Keep discussions focused and productive
Unacceptable Behavior
- Harassment or discriminatory language
- Personal attacks or insults
- Trolling or inflammatory comments
- Publishing others’ private information
Getting Help
GitHub Issues
Ask questions or report problems on GitHub Issues
Documentation
Review the architecture docs for technical details
License
By contributing to Timo, you agree that your contributions will be licensed under the MIT License. The MIT License is permissive and allows:- Commercial use
- Modification
- Distribution
- Private use
Recognition
All contributors will be recognized for their contributions. Your GitHub profile will be displayed in the repository’s contributors list.Questions?
If you have questions about contributing, feel free to:- Open a discussion on GitHub
- Ask in an issue or PR
- Review existing issues for similar questions