Install srt without running its dependencies' install scripts
shellcheck / shellcheck (push) Failing after 17s

srt 0.0.82 optionally depends on @microsoft/mxc-sdk, for Windows
sandboxes, whose koffi and node-pty have install scripts that npm 12
blocks, so every update warned about them (report CD-GB29BZ). srt has
no install scripts of its own and loads that SDK only on Windows, so
--ignore-scripts drops the warning and changes nothing on Linux.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-10 12:54:55 -07:00
co-authored by Claude Opus 5.5
parent 20a2f62300
commit b35ac7d137
+4 -2
View File
@@ -8,9 +8,11 @@
COREDESKTOP="$HOME/.local/share/coredesktop" COREDESKTOP="$HOME/.local/share/coredesktop"
STATUS=0 STATUS=0
# npm's global prefix is under /usr, so install to ~/.local; srt lands in ~/.local/bin # npm's global prefix is under /usr, so install to ~/.local; srt lands in ~/.local/bin.
# srt has no install scripts of its own; the ones npm would otherwise warn it
# blocked belong to the Windows-only @microsoft/mxc-sdk it optionally depends on.
echo "Installing the sandbox runtime (srt)..." echo "Installing the sandbox runtime (srt)..."
npm install --global --prefix "$HOME/.local" --no-fund --no-audit @anthropic-ai/sandbox-runtime || STATUS=1 npm install --global --prefix "$HOME/.local" --no-fund --no-audit --ignore-scripts @anthropic-ai/sandbox-runtime || STATUS=1
# --non-interactive skips Hermes' setup questions and its background gateway # --non-interactive skips Hermes' setup questions and its background gateway
# service; `configure hermes` chooses a model provider afterwards # service; `configure hermes` chooses a model provider afterwards