Reach

From melodic-software/claude-code-plugins · View interactive version

Reach is an AI agent skill from the GitHub repository melodic-software/claude-code-plugins. Reach Claude Code on another host or platform in the fleet to run, prompt, query, message or start a session. Use when: 'run this on HOST', 'ask the desktop to', 'cross-machine', 'remote agent', 'reach the fleet', 'message the Windows session', 'from WSL to Windows', 'share one account across platfo

How to use this skill

Skill file

Resolve the target first

A host is one machine in the fleet. A platform is where Claude Code runs on a host: native

Windows or the WSL distro here (windows, wsl, linux or macos in general). Each platform on each host

is one Claude Code install with its own sign-in.

  1. Read ~/.config/fleet/FLEET.md before composing anything. It holds the real aliases, accounts

and paths for this machine; the commands below use placeholders. Done when you can name the

target host and platform and see its reach entries (alias, port, account, shell).

  1. Pick the platform by the work. WSL is the default agent platform (repos, toolchain, sshd); use

Windows only for Windows-only work or a Windows-side session. Done when you hold a matrix row

with every placeholder filled.

  1. A host absent from FLEET.md is not a fleet host: say so and stop. Address machines by hostname

over the tailnet, never by session name.

Route matrix

<agent> is the headless turn from Verbs: claude on a WSL platform, <claude-exe> on a

Windows platform. "Tested" means a real run of that exact shape; what each run showed is in

reference/relay.md. The R2 and R3 runs passed the prompt

as an argument; their stdin form below has not been re-probed.

| # | From | To | Command shape | Status |

|---|---|---|---|---|

| R0 | any | same platform | Built-in ListAgents / SendMessage. Not this skill | n/a |

| R1 | WSL | this machine, Windows | cd <win-dir> && <claude-exe> <agent-args> "<prompt>" < /dev/null | tested: script (powershell.exe), list, multi-turn, message a -n receiver |

| R2 | WSL | other machine, WSL | printf '%s\n' '<prompt>' \| <ssh> <wsl-alias> 'claude <agent-args>' | tested: script, multi-turn, stream-json, --bg, message an interactive session and a -p receiver across accounts |

| R3 | WSL | other machine, Windows | printf '%s\n' '<prompt>' \| <ssh> <wsl-alias> 'cd <win-dir> && <claude-exe> <agent-args>' | reaches claude.exe; needs /login at that machine's console |

| R4 | Windows | this machine, WSL | wsl.exe -d <distro> --cd /tmp --exec <shell> -lc 'claude <agent-args> "<prompt>" < /dev/null' | tested: script from a native-Windows claude.exe (its Bash tool, Git Bash); list |

| R5 | Windows | other machine, WSL | printf '%s\n' '<prompt>' \| ssh.exe <wsl-alias> 'claude <agent-args>' | untested from a Windows origin (same hop as R2) |

| R6 | Windows | other machine, Windows | printf '%s\n' '<prompt>' \| ssh.exe <wsl-alias> 'cd <win-dir> && <claude-exe> <agent-args>' | untested from a Windows origin (same hop as R3) |

Over SSH a -p turn's prompt goes on stdin, and the quoted remote command carries only the flags,

so no shell on either host parses prompt text. Never add ssh -n to an SSH row: it replaces stdin

with /dev/null and drops the prompt. The local hops (R1, R4) keep the prompt as the last

argument. A verb with no <prompt> drops the printf on an SSH row and the quoted prompt on R1

and R4. --bg is not -p and takes its prompt as an argument, so a background session's prompt

stays inside the remote command. In the tables here and in FLEET.md, \| is an escaped |: type a bare |.

A script with no agent goes over the same hop with the command in place of the claude part; on

R1 that is powershell.exe -NoProfile -Command '<cmd>' from a Windows-side directory. A Windows

script on another machine goes over port 22 instead: <ssh> <win-alias> '<pwsh command>' (see

Port 22).

Placeholders, each filled from FLEET.md or a probe, never guessed:

/mnt/c/Windows/System32/OpenSSH/ssh.exe, because the distro holds no key.

aliases.

working directory), never a repository that defines the fleet's accounts or firewall.

and never ask a subagent's brief to. The hop check in

Verify the hop is what proves them.

PATH.

Per-route detail, the receiver's nested quoting, reply patterns, background sessions, and the

mechanisms not used here (Remote Control, cloud sessions, Channels) are in

reference/relay.md.

Converging dotfiles on any fleet host is not a route in this matrix: run fleet-converge <alias>,

by its bare name. It does not prompt because dotfiles renders an exact allow rule for that command

on every host and platform; no Bash(ssh …) rule is added, and the posture below stands for every other verb.

converge_docs_url option names, ${user_config.converge_docs_url}; empty or still the literal

token means unset, and the command's own machine setup is the only reference.

Verify the hop before you trust it

Run the row with hostname && before the agent, -p as <agent-args> and echo ok as

<prompt>, for example printf '%s\n' 'echo ok' | <ssh> <wsl-alias> 'hostname && claude -p': the

hostname proves which machine answered, ok that its Claude is signed in. A Windows platform that

answers with a sign-in error routed correctly and is signed out: in our R3 probe that error came

from a platform whose auth status reported loggedIn: false

(reference/relay.md § Verified behavior). Someone signs it

back in with /login at that machine's console (or over RDP). We fix nothing remotely, so no

credential travels in a prompt.

Login expired live.

Verbs

Each verb fills <agent-args> and <prompt> in a matrix row. Every verb but the first starts an

agent, and each agent turn costs real usage, even a one-line turn

(Manage costs: Track your costs; the Cost

row of reference/relay.md § Verified behavior holds what

our probe found and how to re-measure it). When a script can do the job, run the script.

| Verb | <agent-args> | <prompt> | Status |

|---|---|---|---|

| Run a script | none: the command itself replaces claude ... over the same hop | none | tested on R1, R2, R4; port 22 untested |

| Prompt | -p | the task | tested on R1, R2, R4 |

| Multi-turn | -p --session-id <uuid>, then -p --resume <uuid> against the same platform | each turn's prompt | tested on R1, R2 |

| One open pipe | -p --input-format stream-json --output-format stream-json --verbose | none: user messages as NDJSON on stdin | tested on R2 |

| List sessions | -p | List the sessions you can reach | tested on R1, R4 |

| Message a session | -p | SendMessage to <name>: <text> | tested on R1, R2 |

| Named receiver | -p -n <name> --settings '{"crossSessionInbound":"accept"}' | the standing instructions | tested on R1, R2 |

| Background session | --bg --name <name> "<prompt>", not -p, with < /dev/null on an SSH row; manage with claude agents --json --all, stop <id>, rm <id> | none: it is in <agent-args> | tested on R2, trusted directory only |

Nobody answers a question a headless turn asks. When the task touches a PR, issue or branch a

session holds, get that session's name and put it in the prompt, and never tell the target to

take the work over on its own judgment.

in it as reference/relay.md § Start in the target's plugin profile

says. With no profile named, or none applied, say with the result that the profile was not

applied.

sender: in our probe it never reached the sender

(reference/relay.md § Verified behavior). Send the

message, then poll claude agents --json on that platform, or --resume the receiver or read its

output.

Get a notice when another session goes idle

and Non-interactive sessions

live.

stays open; per-turn --resume survives a disconnect. --resume ids belong to the platform that

made them, so resume against the same row. --session-id picks the id up front, so nothing

parses the first turn's output. Generate no id in this session: a command you hand over keeps

<uuid> for whoever runs it to fill, and a turn you run yourself can start with

--output-format json and resume with the session_id it returns (see "Parse the JSON" in

Gotchas). Say with the handed-over commands that the id exists only on that platform's

machine and account, so every follow-up goes to the same row.

untrusted one (reference/relay.md § Verified behavior).

Address claude logs and claude attach by the id from claude agents --json --all (bare

--json lists only active sessions); pass a name only after checking the platform's version against

the CLI reference. logs prints raw TUI output, so read a reply from the transcript

(--resume <id>).

Workspace not trusted when dispatching a background session

live for its message and fix.

CLI reference: CLI commands live.

background session, not a -p receiver. Give either one standing instructions as its prompt:

what to do with each message and when to stop. Delivery rules and the pointer are in

reference/relay.md.

Run Claude Code programmatically: Background tasks at exit

live.

listed.

headless recipes.

message a name from the listing that shows it. When a request names a machine and not a platform,

list each of that machine's platforms (on another machine, one R2 and one R3 turn). That holds for

this machine too: a session "in the same repo" here can sit on either platform, so until the platform is

known, name both routes, R0 for this platform and R1 (from WSL) or R4 (from Windows) for the other.

behavior in reference/relay.md § Verified behavior; when

one stops holding, fetch

Control inbound messages,

Non-interactive sessions,

Start faster with bare mode

and CLI flags live.

Accounts are per host and platform

Each platform signs into its own claude.ai account so one platform's usage never draws down another's (on

the desktop, WSL and Windows differ; the laptop's WSL platform uses a third). So:

each platform's ListAgents shows only its own platform.

ListAgents shows nothing remote, even with Remote Control connected.

The peer tools reach only the same host and platform, and no setting widens them; every other route starts a turn

on the target platform. Do not propose sharing an account: the split is the decision.

(reference/relay.md § Verified behavior); when one is in

doubt, fetch

See which sessions Claude can reach

and

Message sessions on other machines

live.

Port 22 is not an agent hop

ssh-admin is a separate Windows account with no Claude sign-in and no DPAPI. Use port 22 for pwsh

scripts only, with pwsh quoting; anything needing the console user's credentials goes through the

on-demand tasks FLEET.md lists.

Permission and safety posture

these prompt under auto mode by design; let them prompt, and say so with every such command you

run, delegate or hand over. A script is judged on its own content.

When a prompt's cause is in doubt, fetch

Eliminate prompts with auto mode

live.

prompt. If asked to stop the prompting, say what the rule would cost and decline.

both take the distro out from under whatever else uses it. The one exception is a start

fleet-converge makes itself, under the guard its pointer names; never run wsl -d on its

behalf.

history; over SSH it travels on stdin, and the local shell history still records it. No secret

belongs in one.

Boundary

| Neighbor | Owns |

|---|---|

| This skill | Every host and platform other than this session's: the other platform on this host, and both platforms on other hosts |

| Built-in ListAgents / SendMessage | Sessions on this host and platform, under its account |

| Built-in Remote Control | Human use of a platform's session from a phone or the web, under that platform's account. Not agent-to-agent across accounts |

| session-flow:continue-in-background | A detached session on this platform |

| session-flow:orchestrate | Delegation inside one session, to subagents |

| repo-fleet-hygiene:audit | Fleets of repositories. Same word, different subject |

Gotchas

Git Bash's MSYS ssh reaches no agent and fails with Permission denied (publickey), which reads

like a key problem and is not one.

when printf does; our SSH rows send the prompt there, not as an argument, so no shell

on either host parses prompt text. On R1 and R4 redirect < /dev/null, so nothing but the

prompt argument reaches the turn.

Run Claude Code programmatically: Pipe data through Claude

and the piped-content row of CLI commands

live.

printf '%s\n' '<prompt>', and R4 single-quotes the whole command, on the local shell, so a '

in the prompt ("what's") closes that quote early. The rule follows the origin shell, not the

platform:

with '\'', or wrap the prompt argument (on R4, the command) in $'...' and write \'. Doubling ('') silently drops the

apostrophe here: 'what''s' arrives as whats.

or a PowerShell window): on R4, keep the prompt in doubled single quotes (-p ''...'') and

write an apostrophe as ''\''''. Never use -p "..." from PowerShell, with or without a

doubled '' apostrophe. This form ran correctly on every version probed. Run the SSH rows

from bash, zsh or Git Bash, whose printf is a builtin.

As of: 2026-11-04. Recheck trigger: the

about_Parsing

page changes how quotes pass to native commands.

does, run wsl.exe --help on that machine, as

Basic commands: Help command

directs (the page has no section of its own for --exec).

--exec test -s //tmp/x.

MSYS2 Filesystem Paths: Automatic Unix ⟶ Windows Path Conversion

live.

as "interop is broken" when it is not; run the .exe by absolute path.

result, and extract the object first, for example grep '^{' | jq -r .session_id. What a

session-end hook can print is in Hooks: SessionEnd.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.