We love your input! We want to make contributing to Websearch CLI as easy and transparent as possible.
- Fork the repository on GitHub
- Clone your fork locally
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Run tests to ensure nothing is broken
- Commit your changes with clear commit messages
- Push to the branch
- Open a Pull Request on GitHub
- Follow PEP 8 style guidelines
- Use type annotations for all function signatures
- Write docstrings for public functions and classes
- Run
ruff checkbefore committing - Run
mypyto verify type annotations
# Check code style
uv run ruff check websearch/
# Type check
uv run mypy websearch/
# Run all checks before committing
uv run ruff check websearch/
uv run mypy websearch/
uv run pytest tests/- Use clear, descriptive commit messages
- Start with a verb (e.g., "Add feature", "Fix bug", "Update documentation")
- Reference issues and pull requests where relevant
Example:
feat: add search command with Brave API integration
- Add search CLI command
- Support for web, news, images, and videos search types
- Add caching for search results
Closes #123
All new features should include appropriate tests. We use pytest for testing.
# Run all tests
uv run pytest tests/ -v
# Run tests with coverage
uv run pytest tests/ --cov=websearch --cov-report=term-missing
# Run a specific test file
uv run pytest tests/test_fetcher.py -vwebsearch/
├── websearch/
│ ├── __main__.py # CLI entry point
│ ├── main.py # CLI commands
│ └── core/
│ ├── cache/ # URL and search result caching
│ ├── converter/ # HTML to Markdown conversion
│ ├── fetcher/ # HTTP fetching with retry
│ ├── search/ # Search API integration
│ └── types/ # Result and Maybe types
├── tests/ # Test files
└── docs/ # Documentation
- Update documentation if your changes affect the public API
- Add tests for any new functionality
- Ensure all tests pass
- Update the README if relevant
- The PR will be reviewed by maintainers
Please note that this project is released with a Code of Conduct. By participating in this project you agree to abide by its terms.
Feel free to open an issue for general questions or discussions about the project.
For security concerns, please email us at support@nesalia.com instead of opening a public issue.
By contributing to Websearch CLI, you agree that your contributions will be licensed under the MIT License.