Skip to content

Commit 0ac987d

Browse files
Refactor .travis.yml to speed up Travis CI
Separate shellcheck and only install shellcheck package for it.
1 parent 22d3787 commit 0ac987d

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

.travis.yml

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,22 @@ sudo: required
33
services:
44
- docker
55

6-
addons:
7-
apt:
8-
sources:
9-
- debian-sid
10-
packages:
11-
- shellcheck
12-
136
script:
14-
- shellcheck *.sh
15-
- ./test-build.sh $NODE_VERSION
7+
- if [ "true" = "${SHELLCHECK-}" ]; then shellcheck *.sh ; fi
8+
- if [ -n "${NODE_VERSION-}" ]; then ./test-build.sh $NODE_VERSION ; fi
169

1710
env:
18-
matrix :
19-
- NODE_VERSION: '4.8'
20-
- NODE_VERSION: '6.11'
21-
- NODE_VERSION: '7.10'
22-
- NODE_VERSION: '8.1'
11+
- NODE_VERSION: '4.8'
12+
- NODE_VERSION: '6.11'
13+
- NODE_VERSION: '7.10'
14+
- NODE_VERSION: '8.1'
15+
16+
matrix:
17+
include:
18+
env: SHELLCHECK=true
19+
addons:
20+
apt:
21+
sources:
22+
- debian-sid
23+
packages:
24+
- shellcheck

0 commit comments

Comments
 (0)