-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
89 lines (59 loc) · 2.2 KB
/
Makefile
File metadata and controls
89 lines (59 loc) · 2.2 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
# KeepKey Client (browser extension) — make targets.
# Thin wrapper over the project's pnpm scripts so the usual flow
# stays consistent with the stack-wide "use make for everything" rule.
SHELL := /bin/bash
.DEFAULT_GOAL := build
.PHONY: help build build-firefox dev dev-firefox zip zip-firefox \
install reinstall clean clean-bundle clean-turbo clean-deps \
lint lint-fix prettier type-check e2e e2e-firefox \
bump
help: ## Show this help
@awk 'BEGIN {FS = ":.*##"; printf "targets:\n"} /^[a-zA-Z_-]+:.*?##/ { printf " %-18s %s\n", $$1, $$2 }' $(MAKEFILE_LIST)
# ---------- build ----------
build: ## Production build (Chrome) → dist/
pnpm build
build-firefox: ## Production build (Firefox) → dist/
pnpm build:firefox
zip: ## Build + package extension.zip (Chrome) → dist-zip/
pnpm zip
zip-firefox: ## Build + package extension.zip (Firefox) → dist-zip/
pnpm zip:firefox
# ---------- dev ----------
dev: ## Watch-mode dev build (Chrome), HMR on, keeps running
pnpm dev
dev-firefox: ## Watch-mode dev build (Firefox), HMR on, keeps running
pnpm dev:firefox
# ---------- deps ----------
install: ## Install deps (frozen lockfile is fine, mirrors CI)
pnpm install
reinstall: ## Nuke node_modules and reinstall from lockfile
pnpm clean:install
# ---------- clean ----------
clean: ## Full clean (dist, caches, node_modules)
pnpm clean
clean-bundle: ## Clean only dist/ and dist-zip/
pnpm clean:bundle
clean-turbo: ## Clean Turborepo cache
pnpm clean:turbo
clean-deps: ## Clean node_modules only
pnpm clean:node_modules
# ---------- quality ----------
lint: ## Lint with autofix + cache
pnpm lint
lint-fix: ## Lint alias (same behavior as lint)
pnpm lint:fix
prettier: ## Prettier check across the workspace
pnpm prettier
type-check: ## Run TypeScript type-check across all packages
pnpm type-check
# ---------- tests ----------
e2e: ## End-to-end tests (Chrome)
pnpm e2e
e2e-firefox: ## End-to-end tests (Firefox)
pnpm e2e:firefox
# ---------- release ----------
bump: ## Bump version across every package.json. Usage: make bump VERSION=0.0.27
@if [ -z "$(VERSION)" ]; then \
echo "usage: make bump VERSION=<x.y.z>"; exit 1; \
fi
./update_version.sh $(VERSION)