/
config.yml
109 lines (106 loc) 路 2.01 KB
/
config.yml
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
104
105
106
107
108
109
version: 2.1
orbs:
win: circleci/windows@4.1.1
commands:
update-yarn:
steps:
- run:
name: Node version
command: node -v
- run:
name: Update yarn
command: yarn global add yarn@latest
install:
steps:
- run:
name: Install dependencies
command: yarn install --ignore-engines --frozen-lockfile
audit:
steps:
- run:
name: Audit dependencies
command: yarn audit
build:
steps:
- run:
name: Build packages
command: yarn build
lint:
steps:
- run:
name: Lint project
command: yarn lint
format:
steps:
- run:
name: Format project
command: yarn format
deps:
steps:
- run:
name: Check dependencies
command: yarn deps
test:
steps:
- run:
name: Test
command: yarn test-ci
save-cache:
steps:
- save_cache:
key: v{{ .Environment.CIRCLE_CACHE_VERSION }}-{{ arch }}-npm-lock-{{ .Branch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "yarn.lock" }}
paths:
- node_modules
run-all:
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "yarn.lock" }}
- update-yarn
- install
- save-cache
- build
- lint
- format
- deps
- test
run-tests:
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "yarn.lock" }}
- update-yarn
- install
- save-cache
- build
- test
jobs:
v14:
docker:
- image: node:14-buster
steps:
- run-tests
v16:
docker:
- image: node:16-buster
steps:
- run-tests
v18:
docker:
- image: node:18-buster
steps:
- run-tests
windows:
executor:
name: win/default
steps:
- run-tests
workflows:
node:
jobs:
- v14
- v16
- v18
- windows