Merge "fast8 improvements"

This commit is contained in:
Zuul 2019-01-31 03:06:21 +00:00 committed by Gerrit Code Review
commit f715ebfa88
2 changed files with 12 additions and 1 deletions

View File

@ -1,7 +1,17 @@
#!/bin/bash
NUM_COMMITS=${FAST8_NUM_COMMITS:-1}
if [[ $NUM_COMMITS = "smart" ]]; then
# Run on all commits not submitted yet
# (sort of -- only checks vs. "master" since this is easy)
NUM_COMMITS=$(git cherry master | wc -l)
fi
echo "Checking last $NUM_COMMITS commits."
cd $(dirname "$0")/..
CHANGED=$(git diff --name-only HEAD~1 | tr '\n' ' ')
CHANGED=$(git diff --name-only HEAD~${NUM_COMMITS} | tr '\n' ' ')
# Skip files that don't exist
# (have been git rm'd)

View File

@ -91,6 +91,7 @@ basepython = python3
envdir = {toxworkdir}/pep8
commands =
{toxinidir}/tools/fast8.sh
passenv = FAST8_NUM_COMMITS
[testenv:pylint]
basepython = python3