Skip to content

Commit 236578b

Browse files
authored
add circleci config file (#3)
1 parent 5af6fb4 commit 236578b

File tree

1 file changed

+62
-0
lines changed

1 file changed

+62
-0
lines changed

.circleci/config.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
2+
aliases:
3+
- &restore-cache
4+
keys:
5+
- v1-dependencies-{{ .Branch }}-{{ checksum "yarn.lock" }}
6+
# Fallback in case checksum fails
7+
- v1-dependencies-{{ .Branch }}-
8+
9+
- &install
10+
run: yarn --no-progress
11+
12+
- &save-cache
13+
paths:
14+
- node_modules
15+
key: v1-dependencies-{{ .Branch }}-{{ checksum "yarn.lock" }}
16+
17+
version: 2
18+
jobs:
19+
Typecheck:
20+
docker:
21+
- image: circleci/node:8
22+
steps:
23+
- checkout
24+
- restore-cache: *restore-cache
25+
- *install
26+
- run: yarn typecheck
27+
28+
Build:
29+
docker:
30+
- image: circleci/node:8
31+
steps:
32+
- checkout
33+
- restore-cache: *restore-cache
34+
- *install
35+
- run: yarn build
36+
- run: npx bundlesize
37+
- save-cache: *save-cache
38+
39+
Semantic Release:
40+
docker:
41+
- image: circleci/node:8
42+
steps:
43+
- checkout
44+
- restore-cache: *restore-cache
45+
- *install
46+
- run: npx semantic-release
47+
48+
# Workflows enables us to run multiple jobs in parallel
49+
workflows:
50+
version: 2
51+
Build and Deploy:
52+
jobs:
53+
- Typecheck
54+
- Build
55+
- Semantic Release:
56+
requires:
57+
- Typecheck
58+
- Build
59+
filters:
60+
branches:
61+
only:
62+
- master

0 commit comments

Comments
 (0)