forked from rstacruz/penpad
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
54 lines (39 loc) · 1.12 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
default:
@echo
@echo "Makefile targets:"
@grep -E '^[a-zA-Z_-].*?: .*?## .*$$' Makefile | sed 's#\\:#:#g' | awk 'BEGIN {FS = ": .*?## "}; {printf "\033[36m %-20s\033[0m %s\n", $$1, $$2}'
@echo
run ?= docker-compose run --rm web
run_s ?= docker-compose run --rm --service-ports web
yarn: ## Installs packages [alias: i]
$(run) yarn
start: ## Starts the server [alias: s]
$(run_s) yarn develop
up: ## Starts the server in the background
docker-compose up -d
down: ## Stops the server
docker-compose down
bash: ## Runs a shell inside a Docker container [alias: sh]
$(run) bash
jest: ## Jest tests
$(run) yarn jest
jest\:watch: ## Jest tests
$(run) yarn jest --watch
tsc\:check: ## Runs the TypeScript compiler
$(run) yarn tsc
tsc\:watch: ## Runs the TypeScript compiler (watch mode) [alias: t]
$(run) yarn tsc --watch
prettier\:check:
$(run) yarn prettier:check
css_modules\:update: ## Update CSS modules [alias: c]
$(run) yarn css_modules:update
fix: ## Fix whatever can be fixed
$(run) yarn fix
# Aliases
i: yarn
s: start
sh: bash
ts: tsc\:watch
tj: jest\:watch
# Simular CI
ci: yarn tsc\:check jest prettier\:check