Thank you for your interest in contributing! This document outlines the development workflow and quality gates.
# Clone the repository
git clone https://github.com/SoundBlaster/XcodeMCPWrapper.git
cd XcodeMCPWrapper
# Create and activate a virtual environment (recommended on macOS/Homebrew Python)
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install --upgrade pip
# Install in editable mode with dev dependencies
python3 -m pip install -e ".[dev]"All code must pass the following quality gates before being merged:
Run all tests with coverage:
pytest tests/ -v --cov=src --cov-report=termRequirements:
- All tests must pass
- Coverage must remain ≥90%
Check for code issues:
ruff check src/ tests/Auto-fix issues where possible:
ruff check src/ tests/ --fixCheck code formatting:
ruff format --check src/ tests/Apply formatting:
ruff format src/ tests/mypy src/Ensure documentation changes are synced with DocC catalog:
make doccheck-all
# or
python scripts/check_doc_sync.py --allThis checks that changes to docs/*.md files are also reflected in the DocC catalog (Sources/XcodeMCPWrapper/Documentation.docc/) across unstaged, staged, and branch scopes.
Ensure the package builds correctly:
python -m build
twine check dist/*Run all quality gates at once:
make test && make lint && make typecheckOr use this bash script (save as check.sh):
#!/bin/bash
set -e
echo "=== Running Quality Gates ==="
echo "1. Running tests..."
pytest tests/ -v --cov=src --cov-report=term
echo "2. Running linter..."
ruff check src/ tests/
echo "3. Checking format..."
ruff format --check src/ tests/
echo "4. Running type checker..."
mypy src/
echo "5. Checking doc sync..."
python scripts/check_doc_sync.py --all
echo "6. Building package..."
python -m build && twine check dist/*
echo "=== All Quality Gates Passed ==="Make it executable and run:
chmod +x check.sh
./check.shWhen adding new features that require specific commands or dependencies:
Add relevant make targets for the new feature. For example:
# For optional features with extra dependencies
install-feature:
python3 -m pip install -e ".[feature]"
# For feature-specific tests
test-feature:
pytest tests/unit/feature/ tests/integration/feature/ -vThen update the .PHONY line and help target to include the new commands.
If the feature has optional dependencies, add them to [project.optional-dependencies]:
[project.optional-dependencies]
feature = [
"dependency1>=1.0",
"dependency2>=2.0",
]We follow the FLOW.md workflow:
- BRANCH - Create a feature branch from
main - SELECT - Pick a task from the workplan
- PLAN - Create a PRD for the task
- EXECUTE - Implement and run quality gates
- ARCHIVE - Move completed task to archive
- Create a feature branch:
git checkout -b feature/TASK-ID-description - Make your changes and run quality gates
- Commit with clear messages
- Push to your fork
- Create a Pull Request against
main
All PRs trigger GitHub Actions CI which runs:
- Lint & Type Check (Python 3.11)
- Tests (Python 3.9, 3.10, 3.11, 3.12)
- Package Build
See .github/workflows/ci.yml for details.
- Follow PEP 8 guidelines
- Use type hints where possible
- Write docstrings for public functions
- Keep functions focused and small
Open an issue or check the troubleshooting guide.