Thank you for your interest in contributing to Windows-MCP! We welcome contributions from the community to help make this project better. This document provides guidelines and instructions for contributing.
- Code of Conduct
- Getting Started
- Development Workflow
- Testing
- Pull Requests
- Documentation
- Reporting Issues
- Security Vulnerabilities
- Getting Help
By participating in this project, you agree to maintain a respectful and inclusive environment. We expect all contributors to:
- Be respectful and considerate in communication
- Welcome newcomers and help them get started
- Accept constructive criticism gracefully
- Focus on what's best for the community and project
Before you begin, ensure you have:
- Windows OS: Windows 7, 8, 8.1, 10, or 11
- Python 3.13+: Download Python
- UV Package Manager: Install with
pip install uvor see UV documentation - Git: Download Git
- A GitHub account: Sign up here
-
Fork the Repository
Click the "Fork" button on the Windows-MCP repository to create your own copy.
-
Clone Your Fork
git clone https://github.com/YOUR_USERNAME/Windows-MCP.git cd Windows-MCP -
Add Upstream Remote
git remote add upstream https://github.com/CursorTouch/Windows-MCP.git
-
Install Dependencies
uv sync
-
Verify Installation
uv run main.py --help
mainbranch contains the latest stable code- Create feature branches from
mainusing descriptive names:- Features:
feature/add-new-tool - Bug fixes:
fix/click-tool-coordinates - Documentation:
docs/update-readme - Refactoring:
refactor/desktop-service
- Features:
-
Create a New Branch
git checkout -b feature/your-feature-name
-
Make Your Changes
- Write clean, readable code
- Follow the existing code structure
- Add comments for complex logic
- Update documentation as needed
-
Test Your Changes
- Test manually in a safe environment (VM recommended)
- Add automated tests if applicable
- Ensure existing functionality isn't broken
-
Commit Your Changes
git add . git commit -m "Add feature: description of your changes"
While we don't enforce a strict commit message format, please make your commits informative:
Good examples:
Add support for multi-monitor setups in State-ToolFix Click-Tool coordinate offset on high DPI displaysUpdate README with Perplexity Desktop installation stepsRefactor Desktop class to improve error handling
Avoid:
fix bugupdatechanges
We use Ruff for code formatting and linting.
Key Guidelines:
- Line length: 100 characters maximum
- Quotes: Use double quotes for strings
- Naming conventions: Follow PEP 8
snake_casefor functions and variablesPascalCasefor classesUPPER_CASEfor constants
- Type hints: Add type annotations to function signatures
- Docstrings: Use Google-style docstrings for all public functions and classes
Example:
def click_tool(
loc: list[int],
button: Literal['left', 'right', 'middle'] = 'left',
clicks: int = 1
) -> str:
"""Click on UI elements at specific coordinates.
Args:
loc: List of [x, y] coordinates to click
button: Mouse button to use (left, right, or middle)
clicks: Number of clicks (1=single, 2=double, 3=triple)
Returns:
Confirmation message describing the action performed
Raises:
ValueError: If loc doesn't contain exactly 2 integers
"""
if len(loc) != 2:
raise ValueError("Location must be a list of exactly 2 integers [x, y]")
# Implementation...Format Code:
ruff format .Run Linter:
ruff check .If the project has tests (check the tests/ directory):
pytestRun specific test files:
pytest tests/test_desktop.pyRun with coverage:
pytest --cov=src tests/When adding new features:
- Create test files in the
tests/directory matching the module structure - Write unit tests for individual functions
- Write integration tests for tool workflows
- Use fixtures for common test setup
- Mock external dependencies (Windows API calls, file system operations)
Example Test:
import pytest
from src.desktop.service import Desktop
def test_click_tool_validates_coordinates():
"""Test that click_tool raises ValueError for invalid coordinates."""
with pytest.raises(ValueError, match="exactly 2 integers"):
click_tool([100]) # Missing y coordinate- Code follows the project's style guidelines
- All tests pass (if applicable)
- Documentation is updated (README, docstrings, etc.)
- Commit messages are clear and descriptive
- Changes are tested in a safe environment (VM recommended)
- No sensitive information (API keys, passwords) is included
-
Update Your Branch
git fetch upstream git rebase upstream/main
-
Push to Your Fork
git push origin feature/your-feature-name
-
Create Pull Request
- Go to the Windows-MCP repository
- Click "New Pull Request"
- Select your fork and branch
- Fill out the PR template with:
- Description: What does this PR do?
- Motivation: Why is this change needed?
- Testing: How was this tested?
- Screenshots: If applicable (UI changes, new features)
- Related Issues: Link any related issues
-
Respond to Feedback
- Address reviewer comments promptly
- Make requested changes in new commits
- Push updates to the same branch
- Maintainers will review your PR within a few days
- You may be asked to make changes or provide clarification
- Once approved, a maintainer will merge your PR
- Your contribution will be acknowledged in release notes
Good documentation is crucial! When contributing:
- Docstrings: Add to all public functions, classes, and methods
- Comments: Explain complex logic or non-obvious decisions
- Type hints: Help users and tools understand your code
Update relevant documentation files:
- README.md: For user-facing features or installation changes
- SECURITY.md: For security-related changes
- CONTRIBUTING.md: For development process changes
When adding or modifying tools:
- Update the tool's
descriptionparameter inmain.py - Add appropriate
ToolAnnotations - Update the tools list in
README.md - Update
manifest.jsonif needed
Found a bug or have a feature request? Please open an issue!
Include:
- Description: Clear description of the bug
- Steps to Reproduce: Detailed steps to recreate the issue
- Expected Behavior: What should happen
- Actual Behavior: What actually happens
- Environment: Windows version, Python version, MCP client
- Screenshots/Logs: If applicable
Include:
- Description: What feature do you want?
- Use Case: Why is this feature needed?
- Proposed Solution: How might this be implemented?
- Alternatives: Other approaches you've considered
DO NOT report security vulnerabilities through public GitHub issues.
Instead, please:
- Email the maintainers at jeogeoalukka@gmail.com
- Or use GitHub Security Advisories
See our Security Policy for more details.
Need help with your contribution?
- Discord: Join our Discord Community
- Twitter/X: Follow @CursorTouch
- GitHub Discussions: Ask questions in Discussions
- Issues: Open an issue for technical questions
We welcome many types of contributions:
- New Tools: Add new MCP tools for Windows automation
- Bug Fixes: Fix issues in existing tools
- Performance Improvements: Optimize code for speed or efficiency
- Refactoring: Improve code structure and maintainability
- Documentation: Improve README, guides, or docstrings
- Testing: Add test cases or improve test coverage
- Bug Reports: Report issues with detailed information
- Feature Requests: Suggest new features or improvements
- Community Support: Help others in Discord or Discussions
- Translations: Help translate documentation (future)
Contributors are recognized in:
- GitHub contributors page
- Release notes for significant contributions
- Special mentions for major features or fixes
By contributing to Windows-MCP, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to Windows-MCP! Your efforts help make this project better for everyone. 🙏
Made with ❤️ by the CursorTouch community