Skip to content

Commit

Permalink
Make build the default target
Browse files Browse the repository at this point in the history
  • Loading branch information
peteraba committed Mar 6, 2021
1 parent 4825005 commit 20dd119
Showing 1 changed file with 17 additions and 13 deletions.
30 changes: 17 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
build:
XDEBUG_MODE=off ./vendor/bin/phpunit
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache src
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache --standard=PSR12 tests
XDEBUG_MODE=off ./vendor/bin/phpmd src text .phpmd.xml
XDEBUG_MODE=off ./vendor/bin/phan --color

precommit:
git diff --cached --name-only --diff-filter=ACM | grep \\.php | xargs -n 1 php -l
XDEBUG_MODE=off ./vendor/bin/phpunit
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache src
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache --standard=PSR12 tests

install:
ifeq (,$(wildcard /usr/local/bin/composer))
./bin/composer-install.sh
Expand All @@ -13,24 +26,15 @@ endif
update:
XDEBUG_MODE=off composer update

build:
XDEBUG_MODE=off ./vendor/bin/phpunit
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache src
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache --standard=PSR12 tests
XDEBUG_MODE=off ./vendor/bin/phpmd src text .phpmd.xml
XDEBUG_MODE=off ./vendor/bin/phan --color

precommit:
git diff --cached --name-only --diff-filter=ACM | grep \\.php | xargs -n 1 php -l
XDEBUG_MODE=off ./vendor/bin/phpunit
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache src
XDEBUG_MODE=off ./vendor/bin/phpcs -p --colors --cache --standard=PSR12 tests

unit:
XDEBUG_MODE=off ./vendor/bin/phpunit

coverage:
XDEBUG_MODE=coverage ./vendor/bin/phpunit -c phpunit-cov.xml
XDEBUG_MODE=off php-coveralls -vvv --coverage_clover=./tmp/report/clover.xml --json_path=./tmp/report/coveralls-upload.json

pull:
git pull
git submodule update --recursive --remote

.PHONY: install update build precommit unit integration coverage

0 comments on commit 20dd119

Please sign in to comment.