-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
50 lines (43 loc) · 1.75 KB
/
Makefile
File metadata and controls
50 lines (43 loc) · 1.75 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
# List all available make targets
list:
@LC_ALL=C $(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/(^|\n)# Files(\n|$$)/,/(^|\n)# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | sort | grep -E -v -e '^[^[:alnum:]]' -e '^$@$$'
# Clean up repository (remove node_modules, dist, build artifacts, etc.)
clean:
sh ./scripts/cleanup-repository.sh;
# Install dependencies, set up pnpm, and build all packages
install:
# setup pnpm
# see: https://pnpm.io/installation#on-posix-systems
pnpm --help > /dev/null 2>&1 || curl -fsSL https://get.pnpm.io/install.sh | sh -;
pnpm self-update $(shell grep packageManager package.json | cut -d'"' -f4 | cut -d'@' -f2);
# setup node version
# see: https://pnpm.io/cli/runtime
pnpm runtime set node --global `cat .nvmrc`;
# install node modules
pnpm install --ignore-scripts;
# setup husky
pnpm husky;
# build all packages
pnpm build;
# Start Storybook development server (installs dependencies first)
storybook:
@$(MAKE) install;
pnpm --filter storybook-config storybook;
# Run react-scan on local Storybook for performance analysis
storybook-react-scan:
pnpx react-scan@latest http://localhost:6006
# Run all tests (installs dependencies first)
test:
@$(MAKE) install;
pnpm test;
# Run the declaration-emit smoke test (installs dependencies first).
# `install` already runs `pnpm build`, so dist/index.d.ts is fresh
# by the time tsc reads it. See: packages/veto/test/dts-smoke/.
test-dts:
@$(MAKE) install;
pnpm --filter @fuf-stack/veto test:dts;
# Bootstrap or update the 'next' prerelease branch
# Creates .release-please-manifest-next.json with major version bumps
# Re-run this when main catches up to next's major version
bootstrap-next:
sh ./scripts/bootstrap-next-branch.sh;