Skip to content

Commit 2fc3997

Browse files
fix: install nightly toolchain (#10081)
### Description Latest `rustup` stopped installing toolchain by default, we need to handle it ourselves. This is a one off to unblock us. ### Testing Instructions [Turborepo Library Release](https://github.com/vercel/turborepo/actions/runs/13644580496)
1 parent 7a06686 commit 2fc3997

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/turbo-repository/scripts/build.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ script_provided_flags="\
1313
for flag in $user_provided_flags; do
1414
if [[ $flag == --target=* ]]; then
1515
target=${flag#*=}
16-
rustup toolchain install stable --target "$target"
16+
rustup toolchain install nightly-2024-11-22 --target "$target"
1717

1818
# For we need to cross-compile some targets with Zig
1919
# Fortunately, napi comes with a `--zig` flag
@@ -23,7 +23,7 @@ for flag in $user_provided_flags; do
2323
fi
2424
done
2525

26-
node_modules/.bin/napi build "$script_provided_flags" "$user_provided_flags"
26+
node_modules/.bin/napi build $script_provided_flags $user_provided_flags
2727

2828
# Unfortunately, when napi generates a .d.ts file, it doesn't match our formatting rules (it doesn't have semicolons).
2929
# Since there's now way to configure this from napi itself, so we need to run prettier on it after generating it.

rust-toolchain.toml

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[toolchain]
2+
# Needs to be copied to `packages/turbo-repository/scripts/build.sh`
23
channel = "nightly-2024-11-22"
34
components = ["rustfmt", "clippy"]
45
profile = "minimal"

0 commit comments

Comments
 (0)