Skip to content

Commit 391f785

Browse files
committed
find correct bsc
1 parent 89316aa commit 391f785

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

rewatch/src/helpers.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -152,17 +152,18 @@ pub fn create_path_for_path(path: &Path) {
152152

153153
pub fn get_bsc(root_path: &str, workspace_root: Option<String>) -> String {
154154
let subfolder = match (std::env::consts::OS, std::env::consts::ARCH) {
155-
("macos", "aarch64") => "darwinarm64",
156-
("macos", _) => "darwin",
157-
("linux", "aarch64") => "linuxarm64",
158-
("linux", _) => "linux",
159-
("windows", _) => "win32",
155+
("macos", "aarch64") => "darwin-arm64",
156+
("macos", _) => "darwin-x64",
157+
("linux", "aarch64") => "linux-arm64",
158+
("linux", _) => "linux-x64",
159+
("windows", "aarch64") => "win-arm64",
160+
("windows", _) => "win-x64",
160161
_ => panic!("Unsupported architecture"),
161162
};
162163

163164
match (
164165
PathBuf::from(format!(
165-
"{}/node_modules/rescript/{}/bsc.exe",
166+
"{}/node_modules/@rescript/{}/bin/bsc.exe",
166167
root_path, subfolder
167168
))
168169
.canonicalize(),

0 commit comments

Comments
 (0)