Skip to content

Commit 7fdd222

Browse files
committed
fix: fix node version for CI
1 parent f859b54 commit 7fdd222

File tree

2 files changed

+54
-29
lines changed

2 files changed

+54
-29
lines changed

.circleci/config.yml

Lines changed: 51 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,73 @@
1-
version: 2
1+
version: 2.1
22

3-
defaults: &defaults
4-
docker:
5-
- image: circleci/node:10
6-
working_directory: ~/project
3+
executors:
4+
default:
5+
docker:
6+
- image: circleci/node:16
7+
working_directory: ~/project
8+
9+
commands:
10+
attach_project:
11+
steps:
12+
- attach_workspace:
13+
at: ~/project
714

815
jobs:
916
install-dependencies:
10-
<<: *defaults
17+
executor: default
1118
steps:
1219
- checkout
13-
- attach_workspace:
14-
at: ~/project
20+
- attach_project
1521
- restore_cache:
1622
keys:
17-
- v1-dependencies-{{ checksum "package.json" }}
18-
- v1-dependencies-
19-
- run: yarn install
23+
- dependencies-{{ checksum "package.json" }}
24+
- dependencies-
25+
- run:
26+
name: Install dependencies
27+
command: |
28+
yarn install --frozen-lockfile
2029
- save_cache:
21-
key: v1-dependencies-{{ checksum "package.json" }}
30+
key: dependencies-{{ checksum "package.json" }}
2231
paths:
2332
- node_modules
2433
- persist_to_workspace:
2534
root: .
2635
paths:
2736
- .
28-
lint-and-typescript:
29-
<<: *defaults
37+
lint:
38+
executor: default
3039
steps:
31-
- attach_workspace:
32-
at: ~/project
33-
- run: |
34-
yarn run lint
35-
yarn run typescript
36-
40+
- attach_project
41+
- run:
42+
name: Lint files
43+
command: |
44+
yarn lint
45+
typescript:
46+
executor: default
47+
steps:
48+
- attach_project
49+
- run:
50+
name: Typecheck files
51+
command: |
52+
yarn typescript
53+
build-package:
54+
executor: default
55+
steps:
56+
- attach_project
57+
- run:
58+
name: Build package
59+
command: |
60+
yarn prepare
3761
workflows:
38-
version: 2
3962
build-and-test:
4063
jobs:
4164
- install-dependencies
42-
- lint-and-typescript:
65+
- lint:
66+
requires:
67+
- install-dependencies
68+
- typescript:
69+
requires:
70+
- install-dependencies
71+
- build-package:
4372
requires:
4473
- install-dependencies

.github/workflows/main.yaml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Deploy
33
on:
44
push:
55
branches:
6-
- master
6+
- main
77

88
jobs:
99
deploy:
@@ -12,14 +12,10 @@ jobs:
1212
steps:
1313
- uses: actions/checkout@v1
1414

15-
- name: Use Node.js 10
15+
- name: Use Node.js 16
1616
uses: actions/setup-node@v1
1717
with:
18-
version: 10
19-
20-
- name: Use Yarn
21-
run: |
22-
curl -o- -L https://yarnpkg.com/install.sh | bash
18+
version: 16
2319

2420
- name: Install dependencies
2521
run: |

0 commit comments

Comments
 (0)