-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
49 lines (33 loc) · 1.72 KB
/
Makefile
File metadata and controls
49 lines (33 loc) · 1.72 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
include .env
help: ## List all make commands
@awk 'BEGIN {FS = ":.*##"; printf "\n Please use `make <target>` where <target> is one of:\n"} /^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) }' $(MAKEFILE_LIST)
@echo ' '
build: ## Build the project with -d and --no-recreate flags
docker compose up --build --no-recreate -d
install: ## Exec container and make npm install commands
docker compose exec mct_web npm install
bundle:
docker compose exec mct_web npm run bundle
clean: ## Remove all dist/ files
docker compose exec mct_web rm -r dist/*
bash: ## Interact to install new packages or run specific commands in container
docker compose exec -it mct_web bash
dev: # Internal command to run dev npm command script
docker compose exec -it mct_web npm run development
up: ## Run up -d Docker command container will wait for interactions
docker compose up -d
start: up dev ## Up the docker env and run the npm run dev it to
first: build install dev ## Build the env, up it and run the npm install and then run npm run dev it to
stop: ./compose.yml ## Stop and remove containers
docker compose kill
docker compose rm --force
restart: stop start dev ## Stop and restart container
types: ## Run type check and generator
docker compose exec mct_web npm run types
prettier: ## Run prettier the opinionated code formatter in code
docker compose exec mct_web npm run prettier
types-watch: ## Run type check and generator
docker compose exec mct_web npm run types-watch
clear: stop ./compose.yml ## Stop and remove container and orphans
docker compose down -v --remove-orphans
.PHONY: bash build clean help logs start stop types types-watch prettier