Permalink
Browse files

Merge pull request #122 from maxmind/andy/fix-snyk-token

Only run snyk when SNYK_TOKEN is in the env
  • Loading branch information...
wesrice committed Oct 15, 2018
2 parents 51b503c + 09a12a9 commit ca2ee9d6438010511aab26a496d9fad6824a3449
Showing with 3 additions and 3 deletions.
  1. +3 −3 .travis.yml
View
@@ -20,9 +20,9 @@ matrix:
before_install:
- composer install --dev -n --prefer-source
- phpenv rehash
- "if [[ $RUN_SNYK ]]; then sudo apt-get install -y nodejs; npm install -g snyk; fi"
- "if [[ $RUN_SNYK && $SNYK_TOKEN ]]; then sudo apt-get install -y nodejs; npm install -g snyk; fi"
install:
- "if [[ $RUN_SNYK ]]; then snyk test --org=maxmind; fi"
- "if [[ $RUN_SNYK && $SNYK_TOKEN ]]; then snyk test --org=maxmind; fi"
script:
- mkdir -p build/logs
- "if [[ $RUN_LINTER ]]; then vendor/bin/php-cs-fixer fix --verbose --diff --dry-run --config=.php_cs; fi"
@@ -31,7 +31,7 @@ script:
after_script:
- php vendor/bin/coveralls
after_success:
- "if [[ $RUN_SNYK && $TRAVIS_BRANCH == 'master' && $TRAVIS_PULL_REQUEST == 'false' ]]; then snyk monitor --org=maxmind --project-name=maxmind/GeoIP2-php; fi"
- "if [[ $RUN_SNYK && $SNYK_TOKEN && $TRAVIS_BRANCH == 'master' && $TRAVIS_PULL_REQUEST == 'false' ]]; then snyk monitor --org=maxmind --project-name=maxmind/GeoIP2-php; fi"
notifications:
email:
on_failure: always

0 comments on commit ca2ee9d

Please sign in to comment.