This repository has been archived by the owner on Apr 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
79 lines (64 loc) · 2.67 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
SHELL := /bin/sh
.POSIX: # enable POSIX compatibility
.SUFFIXES: # no special suffixes
.DEFAULT_GOAL := default
# dummy entry to force make to do nothing by default
.PHONY: default
default:
@echo "Please choose target explicitly."
# git helper: push current branch to configured remotes
.PHONY: git_push_current_branch
git_push_current_branch:
git remote | xargs -L1 git push --verbose
# git helper: push all tags to all configured remotes
.PHONY: git_push_tags
git_push_tags:
git remote | xargs -L1 git push --verbose --tags
# clean all temporary files (cache, logs, etc)
.PHONY: clean_all
clean_all: website_clean_all
# lint all `composer.json` files
.PHONY: lint_composer_config
lint_composer_config:
composer --strict --no-check-version --working-dir=modules/core validate
composer --strict --no-check-version --working-dir=modules/storage validate
composer --strict --no-check-version --working-dir=website validate
# lint all files against EditorConfig settings
.PHONY: lint_editorconfig
lint_editorconfig:
docker container run --rm --user=$$(id --user):$$(id --group) --volume=$$PWD:/check mstruebing/editorconfig-checker:2.7.2
# lint PHP coding style across all directories
.PHONY: lint_coding_style
lint_coding_style:
docker container run --rm --user=$$(id --user):$$(id --group) --volume=$$PWD:/code ghcr.io/php-cs-fixer/php-cs-fixer:3.49-php8.3 check --verbose --show-progress=dots
# fix PHP coding style across all directories
.PHONY: fix_coding_style
fix_coding_style:
docker container run --rm --user=$$(id --user):$$(id --group) --volume=$$PWD:/code ghcr.io/php-cs-fixer/php-cs-fixer:3.49-php8.3 fix --verbose --show-progress=dots
# website: clean all temporary files (cache, logs, etc)
.PHONY: website_clean_all
website_clean_all: website_clean_assets website_clean_cache website_clean_logs
# website: install dependencies defined for assets
.PHONY: website_install_asset_dependencies
website_install_asset_dependencies:
php website/bin/console -vvv importmap:install
# website: compile assets for production environment
.PHONY: website_compile_assets
website_compile_assets:
php website/bin/console -vvv asset-map:compile
# website: remove all compiled assets
.PHONY: website_clean_assets
website_clean_assets:
rm --force --recursive --verbose website/public/assets/*
# website: remove all cache files
.PHONY: website_clean_cache
website_clean_cache:
rm --force --recursive --verbose website/var/cache
# website: remove all log files
.PHONY: website_clean_logs
website_clean_logs:
rm --force --recursive --verbose website/var/log
# website: lint all Twig templates
.PHONY: website_lint_twig_templates
website_lint_twig_templates:
website/bin/console lint:twig -vvv --show-deprecations