diff --git a/.travis.yml b/.travis.yml index 7815b08..2fb9600 100644 --- a/.travis.yml +++ b/.travis.yml @@ -20,7 +20,7 @@ before_script: - export PATH="$TRAVIS_BUILD_DIR/build:$TRAVIS_BUILD_DIR/vendor/bin:$PATH" script: - - find . -not \( -path './vendor' -prune \) -type f -name '*.php' -print0 | xargs -0 -I file php -l file > /dev/null + - phpcs --standard=phpcs.xml "$TRAVIS_BUILD_DIR" after_success: - deploy-phpdoc-branch.sh diff --git a/composer.json b/composer.json index 14f174d..5894970 100644 --- a/composer.json +++ b/composer.json @@ -29,7 +29,8 @@ "symfony/yaml" : "^2.3" }, "require-dev" : { - "phpdocumentor/phpdocumentor": "^2.8" + "phpdocumentor/phpdocumentor": "^2.8", + "squizlabs/php_codesniffer": "^2.4" }, "autoload": { "psr-0": { diff --git a/index.php b/index.php index 40b811a..a4e0fb0 100644 --- a/index.php +++ b/index.php @@ -1,4 +1,6 @@ setConfig(array()); +//$pico->setConfig(array()); // run application echo $pico->run(); diff --git a/phpcs.xml b/phpcs.xml new file mode 100644 index 0000000..6e8d640 --- /dev/null +++ b/phpcs.xml @@ -0,0 +1,39 @@ + + + + Pico's coding standards mainly base on the PHP-FIG PSR-2 standard, + but without the MissingNamespace sniff. + + + + ^build/ + ^vendor/ + *.min.js + + + + + + + + + + + + + + + + \ No newline at end of file