-
Notifications
You must be signed in to change notification settings - Fork 450
/
Makefile
40 lines (30 loc) · 1.12 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
QA_DOCKER_IMAGE=jakzal/phpqa:alpine
QA_DOCKER_COMMAND=docker run -it --rm -v "$(shell pwd):/project" -w /project ${QA_DOCKER_IMAGE}
dist: cs-full phpstan phpunit
ci: phpstan phpunit-coverage
lint: cs-full-check phpstan
phpstan:
sh -c "${QA_DOCKER_COMMAND} phpstan analyse --configuration phpstan.neon --level 6 ."
cs:
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --diff"
cs-full:
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --using-cache=false --diff"
cs-full-check:
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --using-cache=false --diff --dry-run"
composer-compat:
composer config "platform.ext-mongo" "1.6.16"
composer require alcaeus/mongo-php-adapter --no-update
composer-config-beta:
composer config "minimum-stability" "beta"
composer-install:
rm -f composer.lock && cp composer.json composer.json~
ifdef SYMFONY_VERSION
composer require "symfony/symfony:$(SYMFONY_VERSION)" --no-update --no-interaction
endif
composer update --prefer-dist --no-interaction
mv composer.json~ composer.json
phpunit:
vendor/bin/phpunit
# TODO: output to COV
phpunit-coverage:
phpdbg -qrr vendor/bin/phpunit --coverage-text