python-brick-cinderclient-ext/tools/fast8.sh
Walter A. Boring IV 617108e49d Add fast8 ability to tox
This patch adds the same tox -efast8 check for testing pep8 violations
against future patches.  This is a bit faster, because it only tests what
has changed in your current repo.

Change-Id: I6eff6b5f57d947f8c1d0c832227d0f7e15d4bc6f
2016-08-10 07:01:31 -07:00

16 lines
299 B
Bash
Executable File

#!/bin/bash
cd $(dirname "$0")/..
CHANGED=$(git diff --name-only HEAD~1 | tr '\n' ' ')
# Skip files that don't exist
# (have been git rm'd)
CHECK=""
for FILE in $CHANGED; do
if [ -f "$FILE" ]; then
CHECK="$CHECK $FILE"
fi
done
diff -u --from-file /dev/null $CHECK | flake8 --diff