Skip to content

Commit 4a3af1c

Browse files
authored
Merge pull request #170 from markbt/rustup-travis
Use rustup.rs to install Rust in Travis builds
2 parents 65c8e31 + 91cb907 commit 4a3af1c

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

.travis.yml

+13-5
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,25 @@ python:
88
env:
99
- RUST_VERSION=1.25.0
1010
- RUST_VERSION=nightly
11+
matrix:
12+
include:
13+
- python: "3.7"
14+
dist: xenial
15+
sudo: true
16+
env: RUST_VERSION=1.25.0
17+
- python: "3.7"
18+
dist: xenial
19+
sudo: true
20+
env: RUST_VERSION=nightly
1121
sudo: false
1222
install:
1323
- python -c "import sysconfig; print('\n'.join(map(repr,sorted(sysconfig.get_config_vars().items()))))"
14-
- mkdir ~/rust-installer
15-
- curl -sL https://static.rust-lang.org/rustup.sh -o ~/rust-installer/rustup.sh
16-
- sh ~/rust-installer/rustup.sh --prefix=~/rust --spec=$RUST_VERSION -y --disable-sudo
17-
- export PATH="$HOME/rust/bin:$PATH"
24+
- curl -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain "$RUST_VERSION"
25+
- export PATH="$HOME/.cargo/bin:$PATH"
1826
- export PYTHON_LIB=$(python -c "import sysconfig; print(sysconfig.get_config_var('LIBDIR'))")
1927
- find $PYTHON_LIB
2028
- export LIBRARY_PATH="$LIBRARY_PATH:$PYTHON_LIB"
21-
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$PYTHON_LIB:$HOME/rust/lib"
29+
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$PYTHON_LIB"
2230
- rustc -V
2331
script:
2432
- make test extensions

0 commit comments

Comments
 (0)