Skip to content

@stagepass/cli 2.4.0

Choose a tag to compare

@arobertherz arobertherz released this 12 Nov 17:52
· 113 commits to master since this release

CLI-only minor release

Published on npm as @stagepass/cli@2.4.0 on 12 November 2026 at 18:38 Europe/Berlin. Source tag cli-v2.4.0 → 9886c4a541a52cea5e39c828d40980b32eff1d78 (tag object 2f936ad). npm package shasum 43d883c87a97d0efe16332cadc122a402634c07e, integrity sha512-WXaKsuNdnFd6xab/nXUOGvXXzlxxvsr+mg3l8swU0eCb3PQKNcAjfUgigEz/ldCzJn5xbpIxPEQudLJSdc/kAQ==, tarball sha256 d569578e3e5ba2df5352caf085fd808136af68f40a7e4f9fd9cd824a45f6ba34. npm dist-tag latest is 2.4.0. next remains 2.3.0-beta.1.

Install or update with npm install -g @stagepass/cli@latest. If stagepass doctor then reports a daemon version that differs from the CLI, run stagepass autostart on once. The v3 site block needs Caddy 2.9 or newer (brew upgrade caddy).

Loader (2.5.0) and Modules (2.2.2) are separate packages and not part of this release.

Highlights

  • Command suggestions for a misplaced top-level option (#78): for example stagepass --origin <host> suggests stagepass link --origin <host>. Nothing is executed; the hint is stderr-only and the exit code stays non-zero.
  • stagepass watch and stagepass dev write only stable dist/main.js and dist/styles.css (no hash files, no manifest.json writes) (#79). stagepass build still writes hashes, stable copies, and SRI, then removes stale hashed files, including CLI 2.2.x string manifests.
  • stagepass upgrade replaces an unmodified scaffold scripts/build.mjs (#80). Line endings are ignored. An edited script is left unchanged. On a TTY the prompt defaults to yes; without a TTY, and with --yes, the file is replaced.
  • Optional PHP boilerplate from stagepass new --php (plain PHP 8.2, no Composer, no mail) (#82): api/action.php, allowlisted actions, api/.env.example, and .php/config.php. The interactive wizard always asks. doctor, dev, and watch warn when PHP is missing, older than 8.2, or has no php-fpm/php-cgi, and the JS build continues. On a "php": true project, dev / watch start Homebrew php-fpm. stagepass build copies api/ and .php/config.php into dist/ and skips .env, rate-limit files, logs, pid files, and key, certificate, or database files. load_config() reads .env in the project root (the folder that contains api/) and .php/.env. It does not read a file named api/.env. stagepass build never copies those files into dist/. Real environment variables on the host are the safest option. Any .env file you place in the deployed web root needs a deny rule; published 2.4.0 does not ship one.
  • Interactive stagepass new --no-link no longer asks to link on macOS (#83).
  • Linked .sp responses set a single Access-Control-Allow-Origin on HTTP 2xx (Caddy v3). That block needs Caddy 2.9 or newer. When Caddy is known to be older than 2.9, link / reload / start leave existing blocks unchanged and print brew upgrade caddy. doctor reports the version and warns (does not fail) below 2.9.

Full list: CHANGELOG.md section [2.4.0].

Notes for upgraders

  • Known limit, still open on Trello jd36WpR1: without a TTY and without --yes, stagepass upgrade still replaces an unmodified scaffold scripts/build.mjs (same as with --yes). Customised scripts stay untouched.

Verification

  • Self-hosted CI green (Node 22 / 24, e2e) on PR #84 (final head 9886c4a, PR run 43258848863, push 43258834522) and on master after merge (43268292074). The release workflow on tag cli-v2.4.0 succeeded (43269299518) and staged 2.4.0 directly on latest.
  • The published tarball sha256 d569578e3e5ba2df5352caf085fd808136af68f40a7e4f9fd9cd824a45f6ba34 and integrity match the accepted freeze at 9886c4a. Registry gitHead is 9886c4a541a52cea5e39c828d40980b32eff1d78.
  • Docker Node 22 / 24 on the release tree: CLI 737 passed (1 skipped), loader 198, modules 54, packed smoke passed.