Skip to content

Commit d747b8b

Browse files
committed
Only run cargo check for MSRV
It should be enough to verify that the code compiles, we're testing it elsewhere, and we don't need development dependencies to follow MSRV.
1 parent 6eec0c6 commit d747b8b

File tree

1 file changed

+57
-16
lines changed

1 file changed

+57
-16
lines changed

.github/workflows/ci.yml

Lines changed: 57 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,69 @@ jobs:
2525
- name: Run Typos
2626
run: typos
2727

28+
msrv:
29+
name: MSRV
30+
needs: fmt
31+
runs-on: ubuntu-latest
32+
strategy:
33+
fail-fast: false
34+
matrix:
35+
include:
36+
# Android
37+
- target: aarch64-linux-android
38+
39+
# CoreGraphics
40+
- target: aarch64-apple-darwin
41+
- target: x86_64-apple-ios
42+
43+
# Orbital (doesn't follow MSRV)
44+
# - target: x86_64-unknown-redox
45+
46+
# Wayland, KMS/DRM, X11
47+
- target: i686-unknown-linux-gnu
48+
- target: x86_64-unknown-linux-gnu
49+
- target: x86_64-unknown-linux-gnu
50+
features: "x11,x11-dlopen"
51+
- target: x86_64-unknown-linux-gnu
52+
features: "wayland,wayland-dlopen"
53+
- target: x86_64-unknown-linux-gnu
54+
features: "kms"
55+
- target: x86_64-unknown-freebsd
56+
- target: x86_64-unknown-netbsd
57+
features: "x11,x11-dlopen,wayland,wayland-dlopen"
58+
59+
# Web
60+
- target: wasm32-unknown-unknown
61+
62+
# Win32
63+
- target: x86_64-pc-windows-msvc
64+
- target: x86_64-pc-windows-gnu
65+
66+
steps:
67+
- uses: actions/checkout@v6
68+
- uses: hecrj/setup-rust-action@v2
69+
with:
70+
rust-version: '1.71.1'
71+
targets: ${{ matrix.target }}
72+
73+
- name: Pin deps that break MSRV
74+
if: matrix.rust_version == '1.71.0'
75+
run: |
76+
cargo update -p bumpalo --precise 3.14.0
77+
cargo update -p toml_edit --precise 0.23.5
78+
cargo update -p indexmap --precise 2.11.4
79+
cargo update -p toml_datetime --precise 0.7.1
80+
81+
- name: Check that crate compiles
82+
run: cargo check --verbose --target ${{ matrix.target }} ${{ matrix.features && '--no-default-features --features' }} ${{ matrix.features }}
83+
2884
tests:
2985
name: Tests
3086
needs: fmt
3187
strategy:
3288
fail-fast: false
3389
matrix:
34-
rust_version: ['1.71.0', stable, nightly]
90+
rust_version: [stable, nightly]
3591
platform:
3692
- { target: x86_64-pc-windows-msvc, os: windows-latest, }
3793
- { target: i686-pc-windows-msvc, os: windows-latest, }
@@ -49,10 +105,6 @@ jobs:
49105
- { target: x86_64-unknown-netbsd, os: ubuntu-latest, options: --no-default-features, features: "x11,x11-dlopen,wayland,wayland-dlopen" }
50106
- { target: aarch64-apple-darwin, os: macos-latest, }
51107
- { target: wasm32-unknown-unknown, os: ubuntu-latest, }
52-
exclude:
53-
# Orbital doesn't follow MSRV
54-
- rust_version: '1.71.0'
55-
platform: { target: x86_64-unknown-redox, os: ubuntu-latest }
56108
include:
57109
- rust_version: nightly
58110
platform: { target: wasm32-unknown-unknown, os: ubuntu-latest, options: "-Zbuild-std=panic_abort,std", rustflags: "-Ctarget-feature=+atomics,+bulk-memory" }
@@ -95,17 +147,6 @@ jobs:
95147
if: (matrix.platform.os == 'ubuntu-latest') && contains(matrix.platform.target, 'i686')
96148
run: sudo apt-get install gcc-multilib
97149

98-
- name: Pin deps that break MSRV
99-
if: matrix.rust_version == '1.71.0'
100-
run: |
101-
cargo update -p dpi --precise 0.1.1
102-
cargo update -p image --precise 0.25.6
103-
cargo update -p zune-jpeg --precise 0.4.14
104-
cargo update -p half --precise 2.4.1
105-
cargo update -p bumpalo --precise 3.14.0
106-
cargo update -p rayon --precise 1.10.0
107-
cargo update -p rayon-core --precise 1.12.1
108-
109150
- name: Build crate
110151
shell: bash
111152
run: cargo $CMD build --verbose --target ${{ matrix.platform.target }} $OPTIONS --features $FEATURES

0 commit comments

Comments
 (0)