Contributing¶
Development Setup¶
# Clone
git clone https://github.com/BeshoyEhab/dot-man.git
cd dot-man
# Install with dev dependencies
uv sync --extra dev
# Run checks
uv run black dot_man/ tests/
uv run ruff check dot_man/ tests/
uv run mypy dot_man/ --ignore-missing-imports
uv run pytest tests/ -v
Pre-commit Hooks¶
Runs Black, ruff, and mypy automatically on every commit.
Code Style¶
- Formatter: Black (line length 88)
- Linter: ruff (rules: E, F, W, I)
- Type checker: mypy (
--ignore-missing-imports)
Adding Commands¶
- Create
dot_man/cli/<command>_cmd.py - Import in
dot_man/cli/__init__.py - Add completions in
dot_man/cli/common.py - Add tests in
tests/test_<command>_cmd.py - Update docs and CHANGELOG
Testing¶
# All tests
uv run pytest tests/ -v
# Specific file
uv run pytest tests/test_core.py -v
# With coverage
uv run pytest --cov=dot_man --cov-report=term