Skip to content

Commit 11c4af7

Browse files
committed
Move formatting to a separate build
1 parent fc37ad4 commit 11c4af7

File tree

1 file changed

+18
-8
lines changed

1 file changed

+18
-8
lines changed

.travis.yml

+18-8
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
1-
language: cpp
1+
language: scala
22
sudo: required
3-
compiler: gcc
3+
os: linux
4+
dist: trusty
5+
jdk: oraclejdk8
46

5-
script:
7+
scala:
8+
- "2.11.12"
9+
10+
before_script:
611
- docker-compose build $TEST_ENV
12+
13+
script:
714
- docker-compose run $TEST_ENV
8-
- if [[ "$TEST_ENV" = *llvm-5.0 ]]; then
9-
docker-compose run --rm $TEST_ENV scripts/scalafmt --test;
10-
docker-compose run --rm $TEST_ENV scripts/clangfmt --test;
11-
fi
1215
- if [[ "$TEST_ENV" = *llvm-6.0 ]]; then
1316
export VERSION="${TRAVIS_COMMIT}";
1417
docker-compose build bindgen;
@@ -29,6 +32,12 @@ matrix:
2932
on:
3033
branch: master
3134
- env: TEST_ENV=ubuntu-18.04-llvm-5.0
35+
- env: TEST_ENV=formatting
36+
before_script:
37+
- clang-format --version
38+
script:
39+
- scripts/scalafmt --test;
40+
- scripts/clangfmt --test;
3241

3342
before_cache:
3443
# See https://www.scala-sbt.org/1.0/docs/Travis-CI-with-sbt.html
@@ -39,4 +48,5 @@ before_cache:
3948
cache:
4049
directories:
4150
- "$HOME/.ivy2/cache"
42-
- "$HOME/.sbt/boot"
51+
- "$HOME/.sbt/boot/scala-*"
52+
- "$HOME/.coursier"

0 commit comments

Comments
 (0)