Skip to content

Commit 07f72bb

Browse files
fix(workspace): specify RUSTFLAGS through cargo
Wihtout it, the .vscode/settings.json was setting a `RUSTFLAGS` value that was not shared by the cargo cli version, causing unneccessary rebuilds between `cargo build` and an editor save.
1 parent b7c13f6 commit 07f72bb

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.vscode/settings.json

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
{
2-
"rust-analyzer.cargo.extraEnv": {
3-
"RUSTFLAGS": "--cfg codspeed"
4-
},
52
"rust-analyzer.cargo.features": "all",
63
"editor.formatOnSave": true,
74
"rust-analyzer.checkOnSave": true,

Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,6 @@ members = [
66
"crates/cargo-codspeed",
77
]
88
resolver = "2"
9+
10+
[build]
11+
rustflags = ["--cfg codspeed"]

0 commit comments

Comments
 (0)