-
-
Notifications
You must be signed in to change notification settings - Fork 496
/
Makefile
125 lines (98 loc) · 2.59 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
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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
# DO NOT EDIT THIS FILE!
#
# It's auto-generated by sonata-project/dev-kit package.
all:
@echo "Please choose a task."
.PHONY: all
lint: lint-composer lint-yaml lint-xml lint-xliff lint-php
.PHONY: lint
lint-composer:
composer-normalize --dry-run
composer validate
.PHONY: lint-composer
lint-yaml:
yamllint .
.PHONY: lint-yaml
lint-xml:
find . -name '*.xml' \
-not -path './vendor/*' \
-not -path './src/Resources/public/vendor/*' \
| while read xmlFile; \
do \
XMLLINT_INDENT=' ' xmllint --encode UTF-8 --format "$$xmlFile"|diff - "$$xmlFile"; \
if [ $$? -ne 0 ] ;then exit 1; fi; \
done
.PHONY: lint-xml
lint-xliff:
find . -name '*.xliff' \
-not -path './vendor/*' \
-not -path './src/Resources/public/vendor/*' \
| while read xmlFile; \
do \
XMLLINT_INDENT=' ' xmllint --encode UTF-8 --format "$$xmlFile"|diff - "$$xmlFile"; \
if [ $$? -ne 0 ] ;then exit 1; fi; \
done
.PHONY: lint-xliff
lint-php:
vendor/bin/php-cs-fixer fix --ansi --verbose --diff --dry-run
.PHONY: lint-php
lint-symfony: lint-symfony-container lint-symfony-twig lint-symfony-xliff lint-symfony-yaml
.PHONY: lint-symfony
lint-symfony-container:
bin/console lint:container
.PHONY: lint-symfony-container
lint-symfony-twig:
bin/console lint:twig src tests
.PHONY: lint-symfony-twig
lint-symfony-xliff:
bin/console lint:xliff src tests
.PHONY: lint-symfony-xliff
lint-symfony-yaml:
bin/console lint:yaml src tests
.PHONY: lint-symfony-yaml
cs-fix: cs-fix-php cs-fix-xml cs-fix-xliff cs-fix-composer
.PHONY: cs-fix
cs-fix-php:
vendor/bin/php-cs-fixer fix --verbose
.PHONY: cs-fix-php
cs-fix-xml:
find . -name '*.xml' \
-not -path './vendor/*' \
-not -path './src/Resources/public/vendor/*' \
| while read xmlFile; \
do \
XMLLINT_INDENT=' ' xmllint --encode UTF-8 --format "$$xmlFile" --output "$$xmlFile"; \
done
.PHONY: cs-fix-xml
cs-fix-xliff:
find . -name '*.xliff' \
-not -path './vendor/*' \
-not -path './src/Resources/public/vendor/*' \
| while read xmlFile; \
do \
XMLLINT_INDENT=' ' xmllint --encode UTF-8 --format "$$xmlFile" --output "$$xmlFile"; \
done
.PHONY: cs-fix-xliff
cs-fix-composer:
composer-normalize
.PHONY: cs-fix-composer
build:
mkdir $@
test:
vendor/bin/phpunit -c phpunit.xml.dist
.PHONY: test
coverage:
vendor/bin/phpunit -c phpunit.xml.dist --coverage-clover build/logs/clover.xml
.PHONY: coverage
docs:
cd docs && sphinx-build -W -b dirhtml -d _build/doctrees . _build/html
.PHONY: docs
phpstan:
vendor/bin/phpstan --memory-limit=1G analyse
.PHONY: phpstan
psalm:
vendor/bin/psalm --php-version=8.3
.PHONY: psalm
rector:
vendor/bin/rector
.PHONY: rector