From f52b3e6e5c383697d716cb28aed313136d78f7cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=BCller?= Date: Wed, 1 Jul 2020 15:02:47 +0200 Subject: [PATCH 1/2] Replace travis with github actions --- .github/workflows/build.yml | 71 +++++++++++++++++++++++++++++++++++++ .travis.yml | 19 ---------- 2 files changed, 71 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..b842821 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,71 @@ +on: [push, pull_request] + +name: Quickstart + +jobs: + check: + name: Check + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v2 + + - name: Install stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + + - name: Run cargo check + uses: actions-rs/cargo@v1 + with: + command: check + args: --all-features + + test: + name: Test Suite + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v2 + + - name: Install stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + + - name: Run cargo test + uses: actions-rs/cargo@v1 + with: + command: test + args: --all-features + + lints: + name: Lints + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v2 + + - name: Install stable toolchain + uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + components: rustfmt, clippy + + - name: Run cargo fmt + uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all -- --check + + - name: Run cargo clippy + uses: actions-rs/cargo@v1 + with: + command: clippy + args: -- -D warnings diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5799a95..0000000 --- a/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ -sudo: false -language: rust -cache: cargo -rust: -- nightly -- beta -- stable -env: - global: - - FEATURES=yaml_enc,bin_enc,ron_enc,mmap -script: -- | - cargo build --features $FEATURES && - cargo test --features $FEATURES && - cargo doc --features $FEATURES -matrix: - allow_failures: - - rust: nightly - fast_finish: true From f37e7a5aebbed4cc982031b2864cc117889cbc8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=BCller?= Date: Wed, 1 Jul 2020 15:06:26 +0200 Subject: [PATCH 2/2] Only build on master push and prs --- .github/workflows/build.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b842821..d18e343 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,8 @@ -on: [push, pull_request] +on: + push: + branches: + - master + pull_request: name: Quickstart