]> git.lizzy.rs Git - rust.git/blob - .travis.yml
Merge branch 'master' into issue_2741
[rust.git] / .travis.yml
1 language: rust
2
3 rust: nightly
4
5 os:
6   - linux
7   # - osx # doesn't even start atm. Not sure what travis is up to. Disabling to reduce the noise
8
9 sudo: false
10
11 env:
12  global:
13    # TRAVIS_TOKEN_CLIPPY_SERVICE
14    - secure: dj8SwwuRGuzbo2wZq5z7qXIf7P3p7cbSGs1I3pvXQmB6a58gkLiRn/qBcIIegdt/nzXs+Z0Nug+DdesYVeUPxk1hIa/eeU8p6mpyTtZ+30H4QVgVzd0VCthB5F/NUiPVxTgpGpEgCM9/p72xMwTn7AAJfsGqk7AJ4FS5ZZKhqFI=
15    - RUST_BACKTRACE=1
16
17 before_install:
18  - |
19     # work-around for issue https://github.com/travis-ci/travis-ci/issues/6307
20     # might not be necessary in the future
21     if [ "$TRAVIS_OS_NAME" == "osx" ]; then
22      command curl -sSL https://rvm.io/mpapis.asc | gpg --import -
23      rvm get stable
24     fi
25
26 install:
27   - |
28     if [ -z ${INTEGRATION} ]; then
29       . $HOME/.nvm/nvm.sh
30       nvm install stable
31       nvm use stable
32       npm install remark-cli remark-lint
33     fi
34
35 matrix:
36   include:
37     - env: BASE_TESTS=true # runs the base tests
38     - env: INTEGRATION=rust-lang/cargo
39     - env: INTEGRATION=rust-lang-nursery/rand
40     - env: INTEGRATION=rust-lang-nursery/stdsimd
41     - env: INTEGRATION=rust-lang-nursery/rustfmt
42     - env: INTEGRATION=rust-lang-nursery/futures-rs
43     - env: INTEGRATION=rust-lang-nursery/failure
44     - env: INTEGRATION=rust-lang-nursery/log
45     - env: INTEGRATION=rust-lang-nursery/chalk
46     - env: INTEGRATION=rust-lang-nursery/rls
47     - env: INTEGRATION=chronotope/chrono
48     - env: INTEGRATION=serde-rs/serde
49     - env: INTEGRATION=Geal/nom
50     - env: INTEGRATION=hyperium/hyper
51     - env: INTEGRATION=rust-lang/cargo
52     - env: INTEGRATION=rust-lang-nursery/rls
53
54 script:
55   - |
56     if [ -z ${INTEGRATION} ]; then
57       ./ci/base-tests.sh
58     else
59       ./ci/integration-tests.sh
60     fi
61
62 after_success: |
63   #!/bin/bash
64   if [ $(uname) == Linux ]; then
65     set -ex
66     if [ -z ${INTEGRATION} ]; then
67       ./.github/deploy.sh
68     else
69       echo "Not deploying, because we're in an integration test run"
70     fi
71     # trigger rebuild of the clippy-service, to keep it up to date with clippy itself
72     if [ "$TRAVIS_PULL_REQUEST" == "false" ] &&
73        [ "$TRAVIS_REPO_SLUG" == "Manishearth/rust-clippy" ] &&
74        [ "$TRAVIS_BRANCH" == "master" ] &&
75        [ "$TRAVIS_TOKEN_CLIPPY_SERVICE" != "" ] ; then
76        curl -s -X POST \
77           -H "Content-Type: application/json" \
78           -H "Accept: application/json" \
79           -H "Travis-API-Version: 3" \
80           -H "Authorization: token $TRAVIS_TOKEN_CLIPPY_SERVICE" \
81           -d "{ \"request\": { \"branch\":\"master\" }}" \
82           https://api.travis-ci.org/repo/gnunicorn%2Fclippy-service/requests
83     else
84       echo "Ignored"
85     fi
86     set +e
87   fi