My original thought, not necessarily how we should do it, given the above documentation:
matrix:
include:
name: pre-commit checks
python: 3.7
env:
PRE_COMMIT=1
script:
- |
if [ "$PRE_COMMIT" ]; then
pip install pre-commit
pre-commit install
pre-commit run --all-files # or whatever it is
exit $? # exit with pre-commits return code
fi
https://pre-commit.com/#usage-in-continuous-integration
My original thought, not necessarily how we should do it, given the above documentation:
Likely this should be part of pcds-ci-helpers. x-ref an issue there: https://github.com/pcdshub/pcds-ci-helpers/issues/12