3 Commits

Author SHA256 Message Date
Alphaeus Mote 3c6897d0be feat(agent): pipeline objects arrive as PowerShell displays them
Output objects were sent as PSObject.ToString(), so anything that was not
already a string came back as a type name or a terse dump:
"System.Collections.Hashtable", "System.Diagnostics.Process (svchost)",
"@{Name=widget; Size=42}".

Both PowerShell engines now pipe the script's output through
`Out-String -Stream -Width 4096`, PowerShell's own formatter: objects
arrive as their table or list view (a hashtable's Name/Value rows,
properties as columns), still streamed line by line as they are produced,
wide enough that tables are not cut short with "…" at 80/120 columns.
Strings pass through unchanged; trailing padding is trimmed; the exit
code is unaffected. Bash output was already text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 22:26:49 -04:00
Alphaeus Mote d11cc480f3 fix(agent): bash scripts get parameters and secrets under their exact names
Windows environment names are case-insensitive, so assigning "ApiKey"
over an inherited "APIKEY" kept the old spelling; bash is case-sensitive
and saw $ApiKey as empty. On any Windows device with a same-named variable
in different case, that parameter or secret silently arrived blank. The
inherited entry is now removed first so the script's name wins.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 22:22:12 -04:00
gsadmin 48d165e360 Script engines: PowerShell 7 in-process, Windows PowerShell 5.1, Bash
CI / build-test (push) Failing after 3m13s
CI / images (push) Has been skipped
Each script picks its engine. The embedded PowerShell 7 engine remains
the default with the full feature set on every platform. Windows
PowerShell 5.1 shells out to powershell.exe with near parity: a
generated wrapper renders parameters as typed PowerShell literals
(hashtables and arrays included), defines the secrets dictionary
(natively case-insensitive), dot-sources the prelude and splats the
payload; progress records are the accepted limitation. Bash runs the
prelude+script with parameters and secrets as environment variables
(complex values as JSON) on unix or via Git Bash on Windows — the WSL
System32 shim is deliberately ignored because it drops environment
variables. Engines unavailable on a device fail the job with a clear
message instead of running.

The editor gains an engine selector that also switches Monaco's
language. Verified with real out-of-process runs: powershell.exe 5.1
(v=5, typed splat, $Secrets) and Git Bash (env-var params + secrets).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-07 19:39:20 -04:00