Skip to content

Commit 2d1f3dd

Browse files
committed
feat(ci): add cargo-semver-checks workflows
1 parent 34b9c04 commit 2d1f3dd

File tree

3 files changed

+69
-8
lines changed

3 files changed

+69
-8
lines changed

.github/workflows/build-events.yml

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ jobs:
2222
RUST_BACKTRACE: 1
2323
steps:
2424
- uses: actions/checkout@v3
25-
2625
- name: Build events
2726
uses: ./.github/actions/rust-build
2827
with:
@@ -34,6 +33,28 @@ jobs:
3433
- uses: actions/checkout@v3
3534
- uses: dtolnay/rust-toolchain@stable
3635
- uses: Swatinem/rust-cache@v2
37-
3836
- name: Test individual event features
3937
run: make check-event-features
38+
semver:
39+
name: semver
40+
needs: [build, check-event-features]
41+
runs-on: ubuntu-latest
42+
strategy:
43+
matrix:
44+
toolchain:
45+
- "1.81.0" # Current MSRV
46+
- stable
47+
steps:
48+
- uses: actions/checkout@v4
49+
- name: Check `lambda-events` semver with only default features
50+
uses: obi1kenobi/cargo-semver-checks-action@v2
51+
with:
52+
rust-toolchain: ${{ matrix.toolchain }}
53+
package: lambda-events
54+
feature-group: default-features
55+
- name: Check `lambda-events` semver with all features
56+
uses: obi1kenobi/cargo-semver-checks-action@v2
57+
with:
58+
rust-toolchain: ${{ matrix.toolchain }}
59+
package: lambda-events
60+
feature-group: all-features

.github/workflows/build-extension.yml

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,36 @@ jobs:
2828
RUST_BACKTRACE: 1
2929
steps:
3030
- uses: actions/checkout@v3
31-
3231
- name: Build Runtime API Client
3332
uses: ./.github/actions/rust-build
3433
with:
3534
package: lambda_runtime_api_client
3635
toolchain: ${{ matrix.toolchain}}
37-
38-
3936
- name: Build Extensions runtime
4037
uses: ./.github/actions/rust-build
4138
with:
4239
package: lambda-extension
4340
toolchain: ${{ matrix.toolchain}}
41+
semver:
42+
name: semver
43+
needs: build-runtime
44+
runs-on: ubuntu-latest
45+
strategy:
46+
matrix:
47+
toolchain:
48+
- "1.81.0" # Current MSRV
49+
- stable
50+
steps:
51+
- uses: actions/checkout@v4
52+
- name: Check `lambda-extension` semver with only default features
53+
uses: obi1kenobi/cargo-semver-checks-action@v2
54+
with:
55+
rust-toolchain: ${{ matrix.toolchain }}
56+
package: lambda-extension
57+
feature-group: default-features
58+
- name: Check `lambda-extension` semver with all features
59+
uses: obi1kenobi/cargo-semver-checks-action@v2
60+
with:
61+
rust-toolchain: ${{ matrix.toolchain }}
62+
package: lambda-extension
63+
feature-group: all-features

.github/workflows/build-runtime.yml

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,21 +27,41 @@ jobs:
2727
RUST_BACKTRACE: 1
2828
steps:
2929
- uses: actions/checkout@v3
30-
3130
- name: Build Runtime API Client
3231
uses: ./.github/actions/rust-build
3332
with:
3433
package: lambda_runtime_api_client
3534
toolchain: ${{ matrix.toolchain}}
36-
3735
- name: Build Functions runtime
3836
uses: ./.github/actions/rust-build
3937
with:
4038
package: lambda_runtime
4139
toolchain: ${{ matrix.toolchain}}
42-
4340
- name: Build HTTP layer
4441
uses: ./.github/actions/rust-build
4542
with:
4643
package: lambda_http
4744
toolchain: ${{ matrix.toolchain}}
45+
semver:
46+
name: semver
47+
needs: build-runtime
48+
runs-on: ubuntu-latest
49+
strategy:
50+
matrix:
51+
toolchain:
52+
- "1.81.0" # Current MSRV
53+
- stable
54+
steps:
55+
- uses: actions/checkout@v4
56+
- name: Check `lambda_runtime_api_client`, `lambda_runtime`, lambda_http` semver with only default features
57+
uses: obi1kenobi/cargo-semver-checks-action@v2
58+
with:
59+
rust-toolchain: ${{ matrix.toolchain }}
60+
package: lambda_runtime_api_client, lambda_runtime, lambda_http
61+
feature-group: default-features
62+
- name: Check `lambda_runtime_api_client`, `lambda_runtime`, lambda_http` semver with all features
63+
uses: obi1kenobi/cargo-semver-checks-action@v2
64+
with:
65+
rust-toolchain: ${{ matrix.toolchain }}
66+
package: lambda_runtime_api_client, lambda_runtime, lambda_http
67+
feature-group: all-features

0 commit comments

Comments
 (0)