-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
72 lines (53 loc) · 1.75 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
CONTAINER_ID = `docker-compose ps -q app`
init:
@cp .env.example .env
@cp compose.example.yml compose.yml
setup:
@make build
@make up
@make composer_install
@docker compose exec app php artisan key:generate
@make migrate_seed
@make cache_clear
@make test_seed
@make permission
@docker compose exec app php artisan storage:link
build:
@docker compose build
composer_install:
@docker compose exec app composer install --ignore-platform-reqs
cache_clear:
@docker compose exec app php artisan cache:clear
@docker compose exec app php artisan view:clear
@docker compose exec app php artisan route:clear
@docker compose exec app php artisan config:clear
permission:
@docker compose exec app chmod -R 777 /code/storage bootstrap/cache
migrate:
@docker compose exec app php artisan migrate
migrate_seed:
@docker compose exec app php artisan migrate:fresh --seed --drop-views
test_seed:
@docker compose exec app php artisan migrate:fresh --seed --drop-views --env=testing
test_feature:
@docker compose exec app bash -c "vendor/bin/phpunit --testsuite Feature --testdox --colors=always"
test_unit:
@docker compose exec app bash -c "vendor/bin/phpunit --testsuite Unit --testdox --colors=always"
bash:
@docker compose exec app bash
ide_helper:
@docker compose exec app php artisan ide-helper:generate
ide_helper_models:
@docker compose exec app php artisan ide-helper:models --dir="infra/EloquentModels"
up:
@docker compose up -d
down:
@docker compose down
cp_vendor:
rm -rf vendor/*
docker cp $(CONTAINER_ID):/code/vendor ./vendor
@echo '"one sync vendor!'
phpstan:
@docker compose exec app bash -c "vendor/bin/phpstan analyse"
phpcs_domain:
@docker compose exec app bash -c "vendor/bin/phpcs --config-set show_warnings 0 && vendor/bin/phpcs domain"