-
Notifications
You must be signed in to change notification settings - Fork 99
/
Makefile
57 lines (43 loc) · 1008 Bytes
/
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
.PHONY: build
build:
node script/build.js
npx tsc --project tsconfig.json
.PHONY: build-demo
build-demo:
node script/build-demo.js
.PHONY: test
test: build build-demo lint test-bun test-no-es6-browser-globals
.PHONY: mock-test
mock-test:
./script/mock-test.bash
.PHONY: test-no-es6-browser-globals
test-no-es6-browser-globals:
node dist/es6/clipboard-polyfill.es6.js
.PHONY: test-bun
test-bun:
bun script/test-bun.ts
.PHONY: dev
dev:
node script/dev.js
.PHONY: lint
lint:
npx @biomejs/biome check ./script ./src
.PHONY: format
format:
npx @biomejs/biome format --write ./script ./src
.PHONY: clean
clean:
rm -rf ./dist
.PHONY: prepack
prepack:
npm run clean && npm run build
# This is here because `npm` has issues with a `script` field named `publish`.
.PHONY: publish
publish:
npm publish
.PHONY: deploy
deploy: build-demo
rsync -avz ./dist/demo/ garron.net:~/garron.net/code/clipboard-polyfill/ \
--exclude .git \
--exclude node_modules \
--exclude .rpt2_cache