You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Show a command preview when a confirm-gated tool is called without confirm #119
When a confirm-gated tool is called with confirm: false it only answers "cancelled. Set confirm=true to proceed." The only way to see what a state-changing tool would run is the process-wide HOMELAB_DRY_RUN, which needs a server restart and affects every tool.
With confirm: false, return a preview: target node and host plus the command that would run (compose files and action, restore snapshot and target, filter URL and new state, and so on). Reuse the dry-run path so the command guard and node lookup still run. Mask any credentials in the preview text.
Who benefits
Users approving composeDown, backupRestore, nodeExec or piReboot through an agent. The agent can show exactly what will happen before asking for confirm: true, which turns the confirm step into an informed decision.
Open questions
Whether confirm should become optional (absent = preview) or stay required.
Acceptance criteria
Every gated tool returns a preview when confirm is false.
confirm-gates.test.ts asserts the preview and that nothing was executed.
Fixed in f1dd197. With confirm: false, all eleven gated tools now return a preview: target node (user@host[:port]), the command(s) they would run with credentials masked, whether the command guard would block them, argument errors, and notes for extra steps. Nothing is executed. confirm stays required (open question resolved conservatively). Verified in confirm-gates.test.ts: each gated tool previews its real command with execSSH never called, plus masking, guard and invalid-argument cases (391 tests passing).
Activity
TMHSDigital commentedon Nov 18, 2026
Fixed in f1dd197. With
confirm: false, all eleven gated tools now return a preview: target node (user@host[:port]), the command(s) they would run with credentials masked, whether the command guard would block them, argument errors, and notes for extra steps. Nothing is executed.confirmstays required (open question resolved conservatively). Verified in confirm-gates.test.ts: each gated tool previews its real command with execSSH never called, plus masking, guard and invalid-argument cases (391 tests passing).