From 3130f5a43d1f9febb890fa48c50b35b03ca1050c Mon Sep 17 00:00:00 2001 From: Andrei <8067229+andrei-ng@users.noreply.github.com> Date: Wed, 12 Jun 2024 11:55:29 +0200 Subject: [PATCH] Add semver github action check (#206) * bump up ci's checkout action to v4 * add semver check github action Signed-off-by: Andrei Gherghescu <8067229+andrei-ng@users.noreply.github.com> --- .github/workflows/ci.yml | 26 ++++++++++++++++++++------ .github/workflows/release.yml | 2 +- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cc5c3c65..261d3677 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,7 @@ jobs: name: Rustfmt runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@nightly with: components: rustfmt @@ -32,7 +32,7 @@ jobs: name: Clippy runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: components: clippy @@ -46,6 +46,20 @@ jobs: # lint the wasm examples - run: cd ${{ github.workspace }}/examples && cargo clippy --target wasm32-unknown-unknown --package "wasm*" + semver: + name: semver + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Check semver + uses: obi1kenobi/cargo-semver-checks-action@v2 + with: + package: plotly + feature-group: only-explicit-features + features: kaleido + rust-toolchain: stable + release-type: minor + test: name: Tests strategy: @@ -54,7 +68,7 @@ jobs: os: [ubuntu-latest, windows-latest, macos-latest] runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - run: cargo test --features plotly_ndarray,plotly_image,kaleido - if: ${{ matrix.os == 'windows-latest' }} @@ -64,7 +78,7 @@ jobs: name: Code Coverage runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: components: llvm-tools-preview @@ -93,7 +107,7 @@ jobs: ] runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - run: cd ${{ github.workspace }}/examples/${{ matrix.example }} && cargo build @@ -105,7 +119,7 @@ jobs: example: [wasm-yew-minimal] runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: targets: wasm32-unknown-unknown diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 88c3d407..e64c3a6e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,7 @@ jobs: name: Deploy to crates.io runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - run: cargo login ${{ env.CRATES_IO_TOKEN }} env: