Use contents of local checkout instead of last commit for validation

Validating only committed files is not useful in the natural
  $test_everything_passes; commit; push
workflow; the failures will not be caught locally, only by Travis later
(and only if PRs are used instead of direct commits to master).

So, use the working directory state instead of last commit for
validations; and remove misleading comments in checks which already use
the working directory state.
This commit is contained in:
Miloslav Trmač
2016-03-21 14:55:32 +01:00
parent 0d94172288
commit d08a3812d2
4 changed files with 2 additions and 7 deletions

View File

@@ -11,7 +11,6 @@ unset IFS
errors=()
for f in "${files[@]}"; do
# we use "git show" here to validate that what's committed passes go lint
failedLint=$(golint "$f")
if [ "$failedLint" ]; then
errors+=( "$failedLint" )