From 5c3e6206c54bdb73d03d0f62a3a89eb2f11addbb Mon Sep 17 00:00:00 2001 From: Jason Karns Date: Sat, 29 Dec 2018 12:09:00 -0500 Subject: [PATCH] Fix travis Travis says that build configuration variables are available to conditional checks, but not the build _environment_. > Also, environment variables from your build configuration (.travis.yml) and repository settings are available, and can be matched using env(FOO), see below. > Note that this means conditions do not have access to the build environment So is TRAVIS_COMMIT_RANGE considered build config or build env? Who knows! But the main concern is that TRAVIS_COMMIT_RANGE is blank for the initial push of a new branch. So let's just disable the verification build for pushes entirely. (Not optimal, but that's what travis is forcing us into.) --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 933c92a2..7e6da7aa 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,4 +6,5 @@ jobs: include: - stage: test - stage: verify definitions + if: type = pull_request script: npm run verify-definitions -- $TRAVIS_COMMIT_RANGE