forked from muglug/psl
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
40 lines (28 loc) · 1.46 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
install-root-dependencies:
composer update
install-coding-standard-dependencies:
cd tools/php-cs-fixer && composer update --ignore-platform-req php
cd tools/php-codesniffer && composer update
install-type-check-dependencies:
cd tools/psalm && composer update
install-unit-tests-dependencies:
cd tools/phpunit && composer update
install: install-root-dependencies install-coding-standard-dependencies install-type-check-dependencies install-unit-tests-dependencies
coding-standard-fix:
php tools/php-cs-fixer/vendor/bin/php-cs-fixer fix --config=tools/php-cs-fixer/.php_cs.dist
php tools/php-codesniffer/vendor/bin/phpcbf --basepath=. --standard=tools/php-codesniffer/.phpcs.xml
coding-standard-check:
php tools/php-cs-fixer/vendor/bin/php-cs-fixer fix --config=tools/php-cs-fixer/.php_cs.dist --dry-run
php tools/php-codesniffer/vendor/bin/phpcs --basepath=. --standard=tools/php-codesniffer/.phpcs.xml
type-check:
php tools/psalm/vendor/bin/psalm -c tools/psalm/psalm.xml
type-coverage:
php tools/psalm/vendor/bin/psalm -c tools/psalm/psalm.xml --shepherd --stats
security-analysis:
php tools/psalm/vendor/bin/psalm -c tools/psalm/psalm.xml --taint-analysis
unit-tests:
php tools/phpunit/vendor/bin/phpunit -c tools/phpunit/phpunit.xml.dist
code-coverage: unit-tests
composer global require php-coveralls/php-coveralls
php-coveralls -x tests/logs/clover.xml -o tests/logs/coveralls-upload.json -v
check: coding-standard-check type-check security-analysis unit-tests