这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion crates/turborepo-lib/src/task_graph/visitor/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,16 @@ impl<'a, T: PackageInfoProvider> CommandProvider for MicroFrontendProxyProvider<
let mut args = vec!["proxy", mfe_path.as_str(), "--names"];
args.extend(local_apps);

// On Windows, a package manager will rework the binary to be a .cmd extension
// since that's what Windows needs
let bin_name = if cfg!(windows) {
"microfrontends.cmd"
} else {
"microfrontends"
};

// TODO: leverage package manager to find the local proxy
let program = package_dir.join_components(&["node_modules", ".bin", "microfrontends"]);
let program = package_dir.join_components(&["node_modules", ".bin", bin_name]);
let mut cmd = Command::new(program.as_std_path());
cmd.current_dir(package_dir).args(args).open_stdin();
cmd
Expand Down
Loading