Remove wsl command line args on non-windows platforms (#37422)

Release Notes:

- N/A
This commit is contained in:
Max Brunsfeld
2025-09-03 03:49:04 +00:00
committed by GitHub
parent 1ed17fdd94
commit f23096034b
2 changed files with 20 additions and 3 deletions
+7 -1
View File
@@ -707,11 +707,16 @@ pub fn main() {
.map(|chunk| [chunk[0].clone(), chunk[1].clone()])
.collect();
#[cfg(target_os = "windows")]
let wsl = args.wsl;
#[cfg(not(target_os = "windows"))]
let wsl = None;
if !urls.is_empty() || !diff_paths.is_empty() {
open_listener.open(RawOpenRequest {
urls,
diff_paths,
wsl: args.wsl,
wsl,
})
}
@@ -1192,6 +1197,7 @@ struct Args {
/// Example: `me@Ubuntu` or `Ubuntu`.
///
/// WARN: You should not fill in this field by hand.
#[cfg(target_os = "windows")]
#[arg(long, value_name = "USER@DISTRO")]
wsl: Option<String>,