wsl_run
Execute shell commands inside a specified WSL distro and capture stdout, stderr, and exit code. Run as a chosen Linux user, set a working directory, or limit timeout to get reliable command results.
Instructions
Run a shell command inside a WSL distro and capture stdout/stderr/exit code.
Args: params (WslRunInput): distro, command, optional user, cwd and timeout.
Returns: str: JSON {"ok": true, "distro": "...", "returncode": N, "stdout": "...", "stderr": "..."}.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |