Skip to content

Commit 8215e7b

Browse files
authored
Msrv check on CI for #668 (#687)
* check msrv on CI Signed-off-by: clux <[email protected]> * determine MSRV from readme Signed-off-by: clux <[email protected]> * ok fine use grep Signed-off-by: clux <[email protected]> * can cache this Signed-off-by: clux <[email protected]>
1 parent 16e667f commit 8215e7b

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/ci.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,29 @@ jobs:
5858
run: cargo test -p examples --example crd_api --no-default-features --features=deprecated,kubederive,native-tls
5959
if: matrix.os == 'ubuntu-latest'
6060

61+
check-msrv:
62+
# Run `cargo check` on our minimum supported Rust version
63+
runs-on: ubuntu-latest
64+
steps:
65+
- uses: actions/checkout@main
66+
- name: Find MSRV
67+
id: msrv
68+
run: |
69+
MSRV=$(grep MSRV README.md | grep -oE "[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+")
70+
echo $MSRV
71+
echo ::set-output name=msrv::${MSRV}
72+
- uses: actions-rs/toolchain@v1
73+
with:
74+
toolchain: ${{ steps.msrv.outputs.msrv }}
75+
profile: minimal
76+
override: true
77+
- uses: Swatinem/rust-cache@v1
78+
- name: Check
79+
uses: actions-rs/cargo@v1
80+
with:
81+
command: check
82+
args: --all
83+
6184
integration:
6285
# Integration tests are linux only
6386
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)