forked from yacosta738/yacosta738.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
90 lines (62 loc) 路 2.57 KB
/
Copy pathMakefile
File metadata and controls
90 lines (62 loc) 路 2.57 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
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
80
81
82
83
84
85
86
87
88
89
90
SHELL := /bin/sh
PNPM ?= pnpm
PORTFOLIO_FILTER := --filter=portfolio
API_FILTER := --filter=yap-api
.DEFAULT_GOAL := help
.PHONY: all help install clean dev build check check-biome test unit e2e preflight ready-to-push \
portfolio-dev portfolio-build portfolio-check \
api-dev api-build api-test deploy \
e2e-headed e2e-debug e2e-ui e2e-report \
ci install-playwright
help: ## Show available targets
@printf "\nProject task runner\n\n"
@printf " %-20s %s\n" "preflight" "Fast local pre-push (check + unit + build, no e2e)"
@printf " %-20s %s\n" "ci" "Full CI pipeline (check + unit + e2e + build)"
@printf " %-20s %s\n" "install-playwright" "Install Playwright browsers (needed once for e2e)"
@printf "\n"
@awk 'BEGIN {FS = ":.*## "} /^[a-zA-Z0-9_.-]+:.*## / {printf " %-20s %s\n", $$1, $$2}' $(MAKEFILE_LIST)
install: ## Install dependencies
$(PNPM) install
install-playwright: ## Install Playwright browsers (needed once for e2e)
$(PNPM) exec playwright install
clean: ## Clean portfolio generated artifacts
$(PNPM) $(PORTFOLIO_FILTER) clean
dev: ## Run all apps in development mode
$(PNPM) dev
build: ## Build all apps
$(PNPM) build
check: ## Run formatting, linting, and app checks
$(PNPM) check
check-biome: ## Run Biome formatting/linting
$(PNPM) check:biome
test: ## Run all tests
$(PNPM) test
unit: ## Run unit tests for all apps
$(PNPM) test:unit
e2e: ## Run end-to-end tests
$(PNPM) test:e2e
preflight: check unit build ## Fast local pre-push (format/lint/check + unit tests + build, no e2e)
ci: check test build ## Full CI pipeline (format/lint/check + all tests + build)
all: preflight ## Alias for preflight
portfolio-dev: ## Start portfolio dev server (http://localhost:4321)
$(PNPM) $(PORTFOLIO_FILTER) dev
portfolio-build: ## Build portfolio app
$(PNPM) $(PORTFOLIO_FILTER) build
portfolio-check: ## Run Astro type checks for portfolio
$(PNPM) $(PORTFOLIO_FILTER) check:astro
api-dev: ## Start API dev server (http://localhost:8787)
$(PNPM) $(API_FILTER) dev
api-build: ## Validate API deploy build (dry-run)
$(PNPM) $(API_FILTER) build
api-test: ## Run API unit tests
$(PNPM) $(API_FILTER) test:unit
deploy: ## Deploy all deployable apps
$(PNPM) run deploy
e2e-headed: ## Run Playwright tests in headed mode (portfolio)
$(PNPM) $(PORTFOLIO_FILTER) test:e2e:headed
e2e-debug: ## Run Playwright tests in debug mode (portfolio)
$(PNPM) $(PORTFOLIO_FILTER) test:e2e:debug
e2e-ui: ## Open Playwright UI mode (portfolio)
$(PNPM) $(PORTFOLIO_FILTER) test:e2e:ui
e2e-report: ## Open Playwright HTML report (portfolio)
$(PNPM) $(PORTFOLIO_FILTER) test:e2e:report