Skip to content

Add Download-mode smart discovery fallback to generated install snippet

Placeholder ppxd requested to merge feat/script-download-mode-fallback into main

Summary

Closes a regression surfaced after PR #329 was reviewed: operators using the Squid Web wizard's "Or download the installer manually" tab skip Step 1 (which writes install-info.json). Step 2's hard `throw "install-info.json not found"` then breaks the whole snippet for Download-mode operators.

Step 2 now smart-discovers the binary in three layers:

Try Source When it hits
1 `%ProgramData%\Squid\Tentacle\install-info.json` → `BinaryPath` field Paste mode (operator ran Step 1) — canonical path
2 `%ProgramFiles%\Squid Tentacle\Squid.Tentacle.exe` Download mode (operator extracted manually to default location)
3 `Get-Command Squid.Tentacle.exe` (PATH lookup) Operator added install dir to PATH

All-fallbacks-exhausted error names every path tried + gives operator three explicit remediation paths.

Test plan

  • Unit: 4 new fallback-chain tests + existing tests updated; 5225/5225 pass
  • Docs: `windows-tentacle-install.md` adds §4b Download mode with scenario table + manual `$tentacle` override workflow
  • Windows CI: existing resilience E2E + new Download-mode E2E

🤖 Generated with Claude Code

Merge request reports

Loading