File tree 1 file changed +12
-1
lines changed
1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 24
24
25
25
before_script :
26
26
- pip install 'travis-cargo<0.2' --user && export PATH=$HOME/.local/bin:$PATH
27
- - cargo install --force cargo-travis && export PATH=$HOME/.cargo/bin:$PATH
27
+ - export PATH=$HOME/.cargo/bin:$PATH
28
+ # `cargo install` fails if the specified binary is already installed, and
29
+ # doesn't yet support a `--if-not-installed` option [0], so for now assume
30
+ # failures mean the package is already installed. If installation truly
31
+ # failed, the build will fail later anyway, when we try to use the installed
32
+ # binary. Note that `cargo install --force` is not a solution, as it always
33
+ # rebuilds from scratch, ignoring the cache entirely.
34
+ #
35
+ # [0]: https://github.com/rust-lang/cargo/issues/2082
36
+ - cargo install cargo-update || echo "cargo-update already installed"
37
+ - cargo install cargo-travis || echo "cargo-travis already installed"
38
+ - cargo install-update -a # updates cargo-travis, if the cached version is outdated
28
39
- rustup component add clippy rustfmt
29
40
30
41
script :
You can’t perform that action at this time.
0 commit comments