Thank you for your interest in contributing to UV-Agent! This document provides guidelines for contributing to the project.
- Python 3.10 or higher
uvpackage manager- Git
- Gemini CLI (for testing)
-
Fork and clone the repository:
git clone https://github.com/saadmanrafat/uv-mcp cd uv-mcp -
Install dependencies:
uv sync
-
Link the extension for development:
gemini extensions link . -
Run tests:
uv run python test_tools.py
-
Create a new branch for your feature/fix:
git checkout -b feature/your-feature-name
-
Make your changes in the appropriate files:
src/uv_mcp/server.py- MCP server and toolssrc/uv_mcp/uv_utils.py- UV utility functionssrc/uv_mcp/diagnostics.py- Environment diagnostics
-
Test your changes:
uv run python test_tools.py
-
Update documentation if needed:
README.md- Main documentationGEMINI.md- AI instructionsCHANGELOG.md- Add entry under [Unreleased]
- Follow PEP 8 guidelines
- Use type hints where appropriate
- Add docstrings to all functions
- Keep functions focused and single-purpose
All changes should include tests. Add test cases to test_tools.py or create new test files as needed.
# Run all tests
uv run python test_tools.py
# Test the MCP server
uv run uv-mcp-
Update the changelog: Add your changes to
CHANGELOG.mdunder the[Unreleased]section. -
Commit your changes:
git add . git commit -m "feat: add your feature description"
Use conventional commit messages:
feat:- New featurefix:- Bug fixdocs:- Documentation changestest:- Test additions/changesrefactor:- Code refactoring
-
Push to your fork:
git push origin feature/your-feature-name
-
Create a Pull Request:
- Go to the original repository
- Click "New Pull Request"
- Select your branch
- Fill in the PR template
- Provide a clear description of the changes
- Reference any related issues
- Ensure all tests pass
- Update documentation as needed
- Keep PRs focused on a single feature/fix
To add a new MCP tool:
-
Define the tool in
server.py:@mcp.tool() def your_tool_name(param: str) -> str: """ Tool description. Args: param: Parameter description Returns: JSON string with results """ # Implementation return json.dumps(result, indent=2)
-
Add utility functions in
uv_utils.pyordiagnostics.py -
Update
GEMINI.mdwith tool usage instructions -
Add tests in
test_tools.py -
Update
README.mdwith tool documentation
When reporting bugs, please include:
- UV-Agent version
- Python version
- UV version
- Operating system
- Steps to reproduce
- Expected vs actual behavior
- Error messages/logs
For feature requests, please describe:
- The problem you're trying to solve
- Your proposed solution
- Any alternatives you've considered
- How it benefits other users
- Be respectful and inclusive
- Welcome newcomers
- Focus on constructive feedback
- Help others learn and grow
- Open an issue for questions
- Check existing issues and PRs
- Review the documentation
By contributing, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to UV-Agent! 🚀