This repository has been archived on 2021-03-28. You can view files and clone it, but cannot push or open issues/pull-requests.
frank/.githooks/pre-commit

12 lines
306 B
Plaintext
Raw Permalink Normal View History

2020-08-28 13:15:08 +02:00
#!/bin/sh
#
# This hooks runs tests and checks if the linter doesn't hate you
# Linting
printf "black......"
make format > /dev/null 2>&1 && printf "OK!\n" || { printf "Fail." && exit 1; }
2020-08-28 13:15:08 +02:00
# Running tests
printf "pytest....."
make test > /dev/null 2>&1 && printf "OK!\n" || { printf "Fail." && exit 1; }