-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathMakefile
More file actions
92 lines (77 loc) · 2.22 KB
/
Makefile
File metadata and controls
92 lines (77 loc) · 2.22 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
ifneq (,$(findstring feature-,$(BRANCH)))
TEMP_NAME=$(subst $(findstring feature-,$(BRANCH)),feature/,$(BRANCH))
else
TEMP_NAME=$(BRANCH)
endif
ifneq (,$(findstring release-,$(TEMP_NAME)))
BRANCH_NAME=$(subst $(findstring release-,$(TEMP_NAME)),release/,$(TEMP_NAME))
else
BRANCH_NAME=$(TEMP_NAME)
endif
unit-tests:
php bin/phpunit --testsuite unit
acceptance-tests:
vendor/bin/behat
functional-tests:
php bin/phpunit --testsuite functional
.PHONY: fix
fix:
npx eslint assets/ --fix
npx stylelint "assets/styles/**/*.scss" --fix
php bin/phpcbf
.PHONY: vendor
analyze:
npm audit --production
npx eslint assets/
npx stylelint "assets/styles/**/*.scss"
composer valid
composer unused --excludePackage=beberlei/doctrineextensions
php bin/console doctrine:schema:valid --skip-sync
php bin/phpcs
php bin/console lint:twig templates/
vendor/bin/twigcs templates/
vendor/bin/yaml-lint config/
php bin/console lint:xliff translations/
vendor/bin/phpcpd --exclude src/Controller/Admin/ --exclude src/Entity --exclude src/Repository src/
vendor/bin/phpmd src/ text .phpmd.xml
php vendor/bin/phpstan analyse -c phpstan.neon src --level 7 --no-progress
.PHONY: tests
tests:
vendor/bin/behat
php bin/phpunit --testdox
fixtures-test:
php bin/console doctrine:fixtures:load -n --env=test
fixtures-dev:
php bin/console doctrine:fixtures:load -n --env=dev
database-test:
php bin/console doctrine:database:drop --if-exists --force --env=test
php bin/console doctrine:database:create --env=test
php bin/console doctrine:schema:update --force --env=test
database-dev:
php bin/console doctrine:database:drop --if-exists --force --env=dev
php bin/console doctrine:database:create --env=dev
php bin/console doctrine:schema:update --force --env=dev
prepare-test:
make database-test
make fixtures-test
prepare-dev:
make database-dev
make fixtures-dev
prepare-build:
make database-test
make fixtures-test
npm run dev
install:
cp .env.dist .env.local
sed -i -e 's/BRANCH/$(BRANCH)/' .env.local
sed -i -e 's/USER/$(DATABASE_USER)/' .env.local
sed -i -e 's/PASSWORD/$(DATABASE_PASSWORD)/' .env.local
composer install
npm install
.PHONY: install
deploy:
composer install
npm install
make database-dev
make fixtures-dev
npm run build