File tree Expand file tree Collapse file tree 1 file changed +32
-19
lines changed Expand file tree Collapse file tree 1 file changed +32
-19
lines changed Original file line number Diff line number Diff line change 1
- # Javascript Node CircleCI 2.0 configuration file
2
- #
3
- # Check https://circleci.com/docs/2.0/language-javascript/ for more details
4
- #
5
1
version : 2
6
- jobs :
7
- build :
8
- docker :
9
- # specify the version you desire here
10
- - image : circleci/node:7.10
11
-
12
- # Specify service dependencies here if necessary
13
- # CircleCI maintains a library of pre-built images
14
- # documented at https://circleci.com/docs/2.0/circleci-images/
15
- # - image: circleci/mongo:3.4.4
16
2
3
+ jobs :
4
+ build-node-common : &build-node-common
17
5
steps :
18
6
- checkout
19
7
20
- # Download and cache dependencies
21
8
- restore_cache :
22
9
keys :
23
10
- dependencies-{{ checksum "package-lock.json" }}
24
11
# fallback to using the latest cache if no exact match is found
25
12
- dependencies-
26
13
27
- - run : npm i
14
+ - run :
15
+ name : Install dependencies
16
+ command : npm i
28
17
29
18
- save_cache :
19
+ key : dependencies-{{ checksum "package-lock.json" }}
30
20
paths :
31
21
- node_modules
32
- key : dependencies-{{ checksum "package-lock.json" }}
33
22
34
- # run tests!
35
- - run : npm run test
23
+ - run :
24
+ name : Test
25
+ command : npm test
26
+
27
+ build-node-6 :
28
+ << : *build-node-common
29
+ docker :
30
+ - image : node:6
31
+
32
+ build-node-7 :
33
+ << : *build-node-common
34
+ docker :
35
+ - image : node:7
36
+
37
+ build-node-8 :
38
+ << : *build-node-common
39
+ docker :
40
+ - image : node:8
41
+
42
+ workflows :
43
+ version : 2
44
+ build_node_versions :
45
+ jobs :
46
+ - build-node-6
47
+ - build-node-7
48
+ - build-node-8
You can’t perform that action at this time.
0 commit comments