-
Notifications
You must be signed in to change notification settings - Fork 100
/
Makefile
103 lines (79 loc) · 2.08 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
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
91
92
93
94
95
96
97
98
99
100
101
102
103
all: test lint typecheck
node_modules: package.json
npm install && /usr/bin/touch node_modules
build:
@echo ""
@echo "=> make $@"
@npx rollup -c --bundleConfigAsCjs
browser:
@./bin/server --exec "npx open-cli http://localhost:8000/test/fetch-api/browser/"
commit:
npx cz
commitlint: node_modules
npx commitlint --from origin/main --to HEAD --verbose
compile: test/fetch-api/api.spec.ts
@echo ""
@echo "=> make $@"
@npx tsc
cov:
npx nyc report --reporter=text-lcov > .reports/coverage.lcov && npx codecov
lint:
@echo ""
@echo "=> make $@"
@npx standard
release:
npx standard-version
release-alpha:
npx standard-version --prerelease alpha
secure:
@echo ""
@echo "=> make $@"
@npx snyk test
test: compile test-fetch test-module
test-fetch: \
test-fetch-browser-native \
test-fetch-browser-whatwg \
test-fetch-node-fetch
test-fetch-browser-native: build
@echo ""
@echo "=> make $@"
@./test/fetch-api/browser/run.sh
test-fetch-browser-whatwg: build
@echo ""
@echo "=> make $@"
@./test/fetch-api/whatwg/run.sh
test-fetch-node-fetch: build
@echo ""
@echo "=> make $@"
@./test/fetch-api/node/run.sh
test-module: \
test-module-web-cjs \
test-module-web-esm \
test-module-node-cjs \
test-module-node-esm \
test-module-react-native
test-module-web-cjs: build
@echo ""
@echo "=> make $@"
@./test/module-system/web.cjs/run.sh
test-module-web-esm: build
@echo ""
@echo "=> make $@"
@./test/module-system/web.esm/run.sh
test-module-node-cjs: build
@echo ""
@echo "=> make $@"
@./test/module-system/node.cjs/run.sh
test-module-node-esm: build
@echo ""
@echo "=> make $@"
@./test/module-system/node.esm/run.sh
test-module-react-native: build
@echo ""
@echo "=> make $@"
@./test/module-system/react-native/run.sh
typecheck:
@echo ""
@echo "=> make $@"
@npx tsc --lib ES6 --noEmit index.d.ts ./test/fetch-api/api.spec.ts
.PHONY: all build deploy lint test test-fetch test-fetch-browser-native test-fetch-browser-whatwg test-fetch-node-fetch test-module test-module-web-cjs test-module-web-esm test-module-node-cjs test-module-node-esm test-module-react-native typecheck