Skip to content

Commit

Permalink
Update TravisCI to use exiting env var
Browse files Browse the repository at this point in the history
$TRAVIS_COMMIT_RANGE was broken but it seems what we're doing is worse and
resulting in false negatives.

The result of the bad range was that we weren't running lint or tests for
things we should have been. It actually looks like $TRAVIS_COMMIT has been
wrong and it's not clear why this has been working at all.
  • Loading branch information
zpao committed Mar 14, 2015
1 parent 68a2f89 commit 08b1515
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@ cache:
- node_modules
before_install:
- |
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
PR_FIRST=$(curl -s https://github.com/${TRAVIS_REPO_SLUG}/pull/${TRAVIS_PULL_REQUEST}.patch | head -1 | grep -o -E '\b[0-9a-f]{40}\b' | tr -d '\n')
TRAVIS_COMMIT_RANGE=$PR_FIRST^..$TRAVIS_COMMIT
fi
git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.md$)|(^(docs|examples))/' || {
echo "Only docs were updated, stopping build process."
exit
Expand Down

0 comments on commit 08b1515

Please sign in to comment.