-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathMakefile
51 lines (41 loc) · 1.86 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
.PHONY: help
help: ## Displays this list of targets with descriptions
@echo "!!!Do not use these commands in real world projects!!! The following commands are available:\n"
@grep -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[32m%-30s\033[0m %s\n", $$1, $$2}'
.PHONY: update-sitepackage
update-sitepackage: ## Update the site package
./Build/DownloadSitePackage/generate_sitepackage.sh
.PHONY: update-composer
update-composer: ## Update the site package
ddev composer install
.PHONY: setup
setup:
ddev typo3 setup --force --create-site '' --password 'db'
ddev typo3 extension:setup
.PHONY: create-editors
create-editors:
ddev typo3 setup:begroups:default -g Both
ddev typo3 backend:user:create --username=e.doe --password=UnsaFe123! --groups=1 [email protected] --no-interaction
ddev typo3 backend:user:create --username=a.doe --password=UnsaFe123! --groups="1,2" [email protected] --no-interaction
@echo "User e.doe demonstrates standard editor permissions, a.doe advanced editor permissions"
.PHONY: update-page-permissions
update-page-permissions:
ddev exec -s db 'mysql --database=mysql -e "UPDATE db.pages set perms_groupid=1"'
.PHONY: update
update: update-sitepackage update-composer update-page-permissions ## Update everything
.PHONY: install
install: update-sitepackage update-composer restart setup create-editors update-page-permissions ## Install everything
.PHONY: restart
restart: ## Restart DDEV
@echo "Restarting DDEV to ensure it can detect TYPO3 version and create additional.php"
ddev restart
.PHONY: delete
delete: ## Delete DDEV and Database
ddev delete --omit-snapshot
rm -rf vendor
rm -rf var
rm -rf public
rm config/system/additional.php
.PHONY: delete-db
delete-db: ## Delete DDEV and Database
ddev exec -s db 'mysql --database=mysql -e "DROP DATABASE db; CREATE DATABASE db;"'