Skip to content
Snippets Groups Projects
pre-push 278 B
#!/usr/bin/env bash

# Checks run before every push
# has to be copied to .git/hooks

echo "Running pre-push hook"
echo "Running flake8 check"
flake8 --append-config=.flake8 src

# $? stores exit value of the last command
if [ $? -ne 0 ]; then
 echo "flake8 failed"
 exit 1
fi