]> git.lizzy.rs Git - rust.git/blob - .travis.yml
Merge branch 'compiletest' into temp_breakage_fix
[rust.git] / .travis.yml
1 language: rust
2
3 rust: nightly
4
5 os:
6   - linux
7   - osx
8   - windows
9
10 sudo: false
11
12 branches:
13   # Don't build these branches
14   except:
15     # Used by bors
16     - trying.tmp
17     - staging.tmp
18
19 env:
20  global:
21    - RUST_BACKTRACE=1
22
23 before_install:
24  - |
25     # work-around for issue https://github.com/travis-ci/travis-ci/issues/6307
26     # might not be necessary in the future
27     if [ "$TRAVIS_OS_NAME" == "osx" ]; then
28      command curl -sSL https://rvm.io/mpapis.asc | gpg --import -
29      rvm get stable
30     fi
31
32 install:
33   - |
34     if [ -z ${INTEGRATION} ]; then
35       if [ "$TRAVIS_OS_NAME" == "linux" ]; then
36         . $HOME/.nvm/nvm.sh
37         nvm install stable
38         nvm use stable
39         npm install remark-cli remark-lint
40       fi
41       if [ "$TRAVIS_OS_NAME" == "windows" ]; then
42         choco install windows-sdk-10.0
43       fi
44     fi
45
46 matrix:
47   include:
48     - os: osx # run base tests on both platforms
49       env: BASE_TESTS=true
50     - os: linux
51       env: BASE_TESTS=true
52     - os: windows
53       env: BASE_TEST=true
54     - env: INTEGRATION=rust-lang/cargo
55     - env: INTEGRATION=rust-lang-nursery/rand
56     - env: INTEGRATION=rust-lang-nursery/stdsimd
57     - env: INTEGRATION=rust-lang-nursery/rustfmt
58     - env: INTEGRATION=rust-lang-nursery/futures-rs
59     - env: INTEGRATION=rust-lang-nursery/failure
60     - env: INTEGRATION=rust-lang-nursery/log
61     - env: INTEGRATION=rust-lang-nursery/chalk
62     - env: INTEGRATION=rust-lang-nursery/rls
63     - env: INTEGRATION=chronotope/chrono
64     - env: INTEGRATION=serde-rs/serde
65     - env: INTEGRATION=Geal/nom
66 # uncomment once https://github.com/rust-lang/rust/issues/55376 is fixed
67 #    - env: INTEGRATION=hyperium/hyper
68   allow_failures:
69   - os: windows
70     env: BASE_TEST=true
71 # prevent these jobs with default env vars
72   exclude:
73     - os: linux
74     - os: osx
75     - os: windows
76
77 script:
78   # uncomment once https://github.com/rust-lang/rust/issues/55376 is fixed
79   # - |
80   #     rm rust-toolchain
81   #     cargo install rustup-toolchain-install-master || echo "rustup-toolchain-install-master already installed"
82   #     RUSTC_HASH=$(git ls-remote https://github.com/rust-lang/rust.git master | awk '{print $1}')
83   #     travis_retry rustup-toolchain-install-master -f -n master $RUSTC_HASH
84   #     rustup default master
85   #     export LD_LIBRARY_PATH=$(rustc --print sysroot)/lib
86   - |
87     if [ -z ${INTEGRATION} ]; then
88       ./ci/base-tests.sh && sleep 5
89     else
90       ./ci/integration-tests.sh && sleep 5
91     fi
92
93 after_success: |
94   #!/bin/bash
95   if [ $(uname) == Linux ]; then
96     set -ex
97     if [ -z ${INTEGRATION} ]; then
98       ./.github/deploy.sh
99     else
100       echo "Not deploying, because we're in an integration test run"
101     fi
102     set +e
103   fi