From 14ca31fb918acff9958c42b76ac34ec107dbe96a Mon Sep 17 00:00:00 2001 From: l0ng-ai <24760907+l0ng-ai@users.noreply.github.com> Date: Wed, 29 Jul 2026 22:07:20 -0700 Subject: [PATCH] docs(core): retire the M8 notes on a WSL target that now exists --- crates/tty7-core/src/core/session.rs | 12 ++++++++---- src/terminal/view.rs | 5 ++--- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/crates/tty7-core/src/core/session.rs b/crates/tty7-core/src/core/session.rs index 3b1e8b7f..bd3530f2 100644 --- a/crates/tty7-core/src/core/session.rs +++ b/crates/tty7-core/src/core/session.rs @@ -187,7 +187,7 @@ impl std::str::FromStr for WorkspaceId { /// | [`Profile`](RemoteTarget::Profile) | A saved [`SshProfile`](crate::core::ssh_profile::SshProfile), by its stable uuid | `ssh-profile:` | /// | [`Alias`](RemoteTarget::Alias) | A `Host` stanza in `~/.ssh/config` | `ssh-alias:` | /// | [`Direct`](RemoteTarget::Direct) | A typed `user@host:port` (QuickConnect) | `ssh-direct:@:` | -/// | [`Wsl`](RemoteTarget::Wsl) | A WSL distro — **M8**, defined only so the key table has no hole | `wsl:` | +/// | [`Wsl`](RemoteTarget::Wsl) | A distribution installed on this computer, as `wsl.exe -l -q` names it | `wsl:` | /// /// Persisted, unlike [`HostId`](crate::host::HostId): this is what survives a /// restart, and the id is derived from it at connect time. @@ -212,9 +212,13 @@ pub enum RemoteTarget { #[serde(default = "default_ssh_port")] port: u16, }, - /// A WSL distribution. **M8 owns the behaviour**; the variant exists now so - /// that [`connection_key`](RemoteTarget::connection_key) is a total function - /// over the table rather than one that grows a case later. + /// A WSL distribution, named exactly as `wsl -d` takes it. + /// + /// **The one machine that is configured zero times**: it is reached by + /// spawning `wsl.exe`, so there is no address, no credential and no host + /// key to spell out anywhere. The picker + /// (`ui::remote_connect::available_hosts`) therefore offers every + /// distribution installed on this computer rather than reading a store. Wsl { distro: String }, /// A `tty7-server --stdio` child process on *this* machine — the workspace /// mirror of [`RouteTarget::LocalStdio`](crate::daemon::router::RouteTarget::LocalStdio), diff --git a/src/terminal/view.rs b/src/terminal/view.rs index f69d418d..3c6ea050 100644 --- a/src/terminal/view.rs +++ b/src/terminal/view.rs @@ -573,8 +573,7 @@ pub(super) enum LoopbackPlan { Direct, /// A remote whose `localhost` *is* the client's — WSL shares the network /// namespace with its Windows host (the exception). No forward is - /// built; the original URL already resolves. Wired now so M8 only has to - /// start constructing `RemoteTarget::Wsl`. + /// built; the original URL already resolves. NoForwardNeeded, /// A native-SSH pane ("连一下"): forward on the pane's own connection, owned /// by the pane, torn down with it. @@ -7161,7 +7160,7 @@ mod tests { /// **The WSL exception.** WSL shares `localhost` with its /// Windows host, so the URL already resolves — building a forward would be - /// pure overhead. Wired now; M8 supplies the target. + /// pure overhead. #[test] fn wsl_workspace_needs_no_forward() { let w = ws(