Python project template for CLI using click.
- pytest
- flake8
- black ⚫
- mypy
- GitHub build workflow
- Makefile
- setup.py starter file
- click
- VS Code project code-workspace
# create Python virtual environment
python -m venv venv
# activate environment (Linux):
source venv/bin/activate
# activate environment (Windows):
venv\Scripts\activate
# install dependencies
pip install -r requirements.txt
To test the CLI during development, install it in edit mode:
pip install -e .
Then, use the CLI with:
foo
# run tests:
make test
# run tests and write test coverage output
mate testcov
Manual releases:
# install dependencies for twine (once)
make prepforbuild
# create distribution package
make artifacts
# upload to the test pypi
make testrelease
# upload to pypi
make release
black .