mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-31 15:47:31 +00:00
Add extra double quotes only on Windows.
As tested by @edwin0cheng, Windows requires the quotes removed in the previous commit. This commit re-adds the quotes gated by an if statement on the node environment, so that quotes are only added on Windows.
This commit is contained in:
parent
4d78c85de2
commit
3a79490187
1 changed files with 4 additions and 0 deletions
|
@ -51,6 +51,10 @@ export class CargoWatchProvider {
|
||||||
// Excape the double quote string:
|
// Excape the double quote string:
|
||||||
args += ' ' + Server.config.cargoWatchOptions.checkArguments;
|
args += ' ' + Server.config.cargoWatchOptions.checkArguments;
|
||||||
}
|
}
|
||||||
|
// Windows handles arguments differently than the unix-likes, so we need to wrap the args in double quotes
|
||||||
|
if (process.platform == "win32") {
|
||||||
|
args = '"' + args + '"';
|
||||||
|
}
|
||||||
|
|
||||||
// Start the cargo watch with json message
|
// Start the cargo watch with json message
|
||||||
this.cargoProcess = child_process.spawn(
|
this.cargoProcess = child_process.spawn(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue