Skip to content
This repository has been archived by the owner on Sep 14, 2023. It is now read-only.

add minimal-versions to CI #242

Merged
merged 2 commits into from
Aug 24, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@ rust:
- stable
- beta
- nightly
before_script:
- rustup toolchain install nightly
script:
- cargo build --verbose
- cargo test --verbose
- cargo doc
- cargo +nightly generate-lockfile -Z minimal-versions
- cargo build --verbose
- cargo test --verbose
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about just running these commands when the nightly matrix entry runs, instead of on every build?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is what I meant with my question about configurations. Is there some easy way to do an if nightly in this style of travis file?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I see what you meant now. Sorry, didn't catch that. And yeah:

script:
  - cargo build --verbose
  - cargo test --verbose
  - cargo doc
  - if [ "$TRAVIS_RUST_VERSION" = "nightly" ]; then
      cargo +nightly generate-lockfile -Z minimal-versions;
      cargo build --verbose;
      cargo test --verbose;
    fi

(Note the semi-colons. This is usually when I start splitting the script section to a shell script, but I'm fine with this for now. I can fix that later if I care.)