Bump to 2021 ed, improve string formatting #589
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rust | |
permissions: write-all | |
on: | |
pull_request: | |
branches: [ master ] | |
types: [ "opened", "synchronize" ] | |
push: | |
branches: [ master ] | |
jobs: | |
doc: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Install cargo-deadlinks | |
run: which deadlinks || cargo install cargo-deadlinks | |
- name: Generate documentation | |
run: cargo doc --all | |
doc-nightly: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Install cargo-deadlinks | |
run: which deadlinks || cargo install cargo-deadlinks | |
- name: Generate documentation | |
run: | | |
rustup install nightly | |
cargo +nightly doc --all | |
# temporarily disabled. | |
# - name: Validate links | |
# run: cargo deadlinks --dir target/doc/glommio | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Build all targets | |
run: cargo build --all --all-targets | |
build-nightly: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Build all targets on the nigthly channel | |
run: > | |
rustup install nightly; | |
cargo +nightly build --all --all-targets --features=nightly | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Install cargo helpers and test all targets | |
run: | | |
cat << EOF > "run-gha-workflow.sh" | |
PATH=$PATH:/usr/share/rust/.cargo/bin | |
echo "`nproc` CPU(s) available" | |
rustup install nightly | |
rustup component add rustfmt --toolchain nightly-x86_64-unknown-linux-gnu | |
rustup install 1.58 | |
rustup show | |
rustup default stable | |
cargo install cargo-sort | |
cargo test -- --test-threads=`nproc` | |
EOF | |
sudo -E bash -c "ulimit -Sl 512 && ulimit -Hl 512 && bash run-gha-workflow.sh" | |
test-nightly: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Cache setup | |
uses: ./.github/actions/cache-setup | |
- name: Install cargo helpers and test all targets on the nigthly channel | |
run: | | |
cat << EOF > "run-gha-workflow.sh" | |
PATH=$PATH:/usr/share/rust/.cargo/bin | |
echo "`nproc` CPU(s) available" | |
rustup install nightly | |
rustup component add rustfmt --toolchain nightly-x86_64-unknown-linux-gnu | |
rustup install 1.58 | |
cargo install cargo-sort | |
rustup show | |
cargo +nightly test --features=nightly -- --test-threads=`nproc` | |
EOF | |
sudo -E bash -c "ulimit -Sl 512 && ulimit -Hl 512 && bash run-gha-workflow.sh" |