Add Travis integration

This commit is contained in:
Jorge A. Torres 2020-09-17 16:53:23 -03:00
parent 6390b52833
commit f2b4cc6eff

22
.travis.yml Normal file
View file

@ -0,0 +1,22 @@
language: php
os: linux
dist: xenial
notifications:
email: false
php:
- 7.0
branches:
only:
- master
- trunk
script: |
CHANGED_FILES=`git diff --name-only --diff-filter=ACMR $TRAVIS_COMMIT_RANGE | grep \\\\.php | awk '{print}' ORS=' '`
if [ "$CHANGED_FILES" != "" ]; then
composer global require woocommerce/woocommerce-sniffs --update-with-all-dependencies
.config/composer/vendor/bin/phpcs -p $CHANGED_FILES
fi