From c2d9001051ea8033772d5aacd5dd1b14d6674ad0 Mon Sep 17 00:00:00 2001 From: Waffle Lapkin Date: Wed, 27 Nov 2019 17:30:33 +0300 Subject: [PATCH] Move CI to github actions --- .github/workflows/ci.yml | 71 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..2a97f3ab --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,71 @@ +on: [push] + +name: Continuous integration + +jobs: + ci: + runs-on: ubuntu-latest + strategy: + matrix: + rust: + - stable + - beta + - nightly + + steps: + - uses: actions/checkout@v1 + + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: ${{ matrix.rust }} + override: true + components: rustfmt, clippy + + - name: stable/beta build + uses: actions-rs/cargo@v1 + if: matrix.rust == 'stable' || matrix.rust == 'beta' + with: + command: build + args: --verbose --features "" + + - name: nightly build + uses: actions-rs/cargo@v1 + if: matrix.rust == 'nightly' + with: + command: build + args: --verbose --all-features + + - name: stable/beta test + uses: actions-rs/cargo@v1 + if: matrix.rust == 'stable' || matrix.rust == 'beta' + with: + command: test + args: --verbose --features "" + + - name: nightly test + uses: actions-rs/cargo@v1 + if: matrix.rust == 'nightly' + with: + command: test + args: --verbose --all-features + + - name: fmt + uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all -- --check + + - name: stable/beta clippy + uses: actions-rs/cargo@v1 + if: matrix.rust == 'stable' || matrix.rust == 'beta' + with: + command: clippy + args: --all-targets --features "" -- -D warnings + + - name: nightly clippy + uses: actions-rs/cargo@v1 + if: matrix.rust == 'nightly' + with: + command: clippy + args: --all-targets --all-features -- -D warnings