Skip to content

Commit 981caa6

Browse files
committed
Fix workspace issues when building for stable.
1 parent 7d975f0 commit 981caa6

File tree

3 files changed

+23
-4
lines changed

3 files changed

+23
-4
lines changed

.github/workflows/test.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
toolchain: ${{ matrix.rust }}
3939
target: ${{ matrix.target }}
4040

41-
- run: sed -i '/nightly-only/d' Cargo.toml
41+
- run: mv Cargo.stable.toml Cargo.toml
4242
if: matrix.rust != 'nightly'
4343

4444
- run: cargo check --target=${{ matrix.target }} --features=${{ matrix.features }}

Cargo.stable.toml

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# CI moves this file to `Cargo.toml` when building for stable.
2+
3+
[workspace]
4+
resolver = "2"
5+
6+
members = [
7+
"embedded-hal",
8+
"embedded-hal-nb",
9+
"embedded-hal-bus",
10+
"embedded-can",
11+
"embedded-io",
12+
"embedded-io-adapters",
13+
]
14+
15+
# Cargo implicitly adds path dependencies to the workspace.
16+
# Even if they're optional and not enabled. This prevents that.
17+
exclude = [
18+
"embedded-hal-async",
19+
"embedded-io-async",
20+
]

Cargo.toml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
[workspace]
22
resolver = "2"
33

4-
# CI removes lines containing 'nightly-only' when not building with nightly.
54
members = [
65
"embedded-hal",
7-
"embedded-hal-async", # nightly-only
6+
"embedded-hal-async",
87
"embedded-hal-nb",
98
"embedded-hal-bus",
109
"embedded-can",
1110
"embedded-io",
12-
"embedded-io-async", # nightly-only
11+
"embedded-io-async",
1312
"embedded-io-adapters",
1413
]

0 commit comments

Comments
 (0)