Third party pull requests help expand pyinfra's functionality and are essential to it's continued growth. This guide should help get you started adding additional modules/facts to pyinfra.
# Create a virtualenv
virtualenv /path/to/venv
# Clone the repo
git clone git@github.com:Fizzadar/pyinfra.git
# Install the package in editable mode with development requirements
pip install -e .[dev]
Use nosetests
or the bundled helper script to run tests. This helper script also counts coverage:
# Test everything (API, modules & facts)
scripts/test.sh
# Set individual bits
scripts/test.sh [api|modules|facts]
- How to write modules (operations + facts)
- API reference
- Always add tests for modules (operations + facts)
- Keep code style consistent:
- ~90 character lines
- no hanging indents
- single quotes everywhere possible