-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
75 lines (58 loc) · 2.4 KB
/
Copy pathmakefile
File metadata and controls
75 lines (58 loc) · 2.4 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#
# Makefile
#
.PHONY: help
.DEFAULT_GOAL := help
help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
clean: ## cleans all dependencies
rm -rf vendor
prod: ## installs all vendors in prod mode
COMPOSER_MEMORY_LIMIT=-1 composer install --no-dev --optimize-autoloader
yarn install --production=true
yarn encore prod
dev: ## installs all vendors in dev mode
COMPOSER_MEMORY_LIMIT=-1 composer install -n
patch -t vendor/symfony/error-handler/ErrorHandler.php custom/patches/dev/SymfonyErrorHandler.patch
yarn install --production=false
yarn encore dev
watch: ## webpack watcher
yarn encore dev --watch
worker-loop: ## starts the worker in a loop
while :; do php bin/console messenger:consume async_checks --limit=10 -v; done
worker: ## starts the worker
php bin/console messenger:consume async_checks -v
scheduler: ## starts the scheduler
php bin/console orcano:scheduler:run -v
result-worker: ## starts the result worker
php bin/console messenger:consume async_results -v
test: ## runs all tests
php vendor/bin/phpunit --configuration=phpunit.xml
test-coverage: ## runs all tests with coverage
phpdbg -qrr vendor/bin/phpunit --configuration=phpunit.xml --coverage-clover=clover.xml --coverage-text
test-coverage-html: ## runs all tests with coverage and generates html report in http://url/coverage
phpdbg -qrr vendor/bin/phpunit --configuration=phpunit.xml --coverage-html=public/coverage
stan: ## starts the PHPStan analyzer
php vendor/bin/phpstan --memory-limit=-1 analyse
checks: ## starts all checks
@make test; TEST_EXIT_CODE=$$?; \
make stan; STAN_EXIT_CODE=$$?; \
make csfix; CSFIX_EXIT_CODE=$$?; \
make rector; RECTOR_EXIT_CODE=$$?; \
echo "----------------------------------------"; \
echo "Test exit code: $$TEST_EXIT_CODE"; \
echo "Stan exit code: $$STAN_EXIT_CODE"; \
echo "CS Fixer exit code: $$CSFIX_EXIT_CODE"; \
echo "Rector exit code: $$RECTOR_EXIT_CODE"
csfix: ## Starts the PHP CS Fixer [mode=no-dry-run] default is dry-run
ifndef mode
@php ./vendor/bin/php-cs-fixer fix --config=./.php-cs-fixer.php --dry-run
else ifeq ($(mode), no-dry-run)
php ./vendor/bin/php-cs-fixer fix --config=./.php-cs-fixer.php
endif
rector: ## Starts rector [mode=no-dry-run] default is dry-run
ifndef mode
@php ./vendor/bin/rector process --dry-run
else ifeq ($(mode), no-dry-run)
php ./vendor/bin/rector process
endif