Repository navigation
winget: a standalone cloudpin.exe (#96) - #101
Merged
Merged
Conversation
Owner-approved decisions for 1.3.0: Node 26 SEA cross-built in the ubuntu release job, cloudpin bundled into one ESM file, unsigned at first, x64 only, Nightly flags Node security releases, paureis.cloudpin as the winget ID, manifests generated by bump-installers and submitted by the owner by hand. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rolldown 1.2.13 was already in the tree through vitest's vite; declaring it at that exact version adds no package. Reinstalled from scratch per CLAUDE.md: 15 @rolldown/binding entries, npm ci succeeds. The fresh resolution also moved two dev-only transitives a patch: postcss 8.5.30 and tinybench 6.2.2. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cli.ts and config.ts each read ../package.json through createRequire, which can't work inside a Node single executable application, where import.meta.url is the exe's path. src/version.ts reads it once, unless the bundler has replaced CLOUDPIN_BUNDLED_VERSION with the literal version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Inside a single executable application (node:sea isSea()) the install is read from the exe's own path: under winget's portable package folder (<root>\Packages\paureis.cloudpin_<source>, user or machine scope) it is winget, anywhere else the exe. Doctor's on-PATH check also knows winget's Links folder, and treats a cloudpin.exe outside every layout as the exe. Advice: winget upgrade paureis.cloudpin, or download the latest cloudpin-X.Y.Z-win-x64.zip from the GitHub releases page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bundles dist/cli.js with yaml and cross-spawn into one ES module (rolldown, the version inlined), refuses a bundle that still reads package.json or loads a package, and runs node --build-sea of the Node pinned in scripts/exe-node-version.txt (26.12.0) with the official win-x64 node.exe of that version as the executable. Every Node file is downloaded from nodejs.org/dist and checked against SHASUMS256.txt. On Linux the linux-x64 node runs --build-sea; on Windows node.exe builds itself. Writes cloudpin-X.Y.Z-win-x64.zip (cloudpin.exe and LICENSE) with windows-zip.mjs's zip writer. --node-version prints the pin; --security-release prints a newer security release of its major line from nodejs.org/dist/index.json. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
After the Windows zip, the publish job runs scripts/build-exe.mjs, which fetches the pinned Node's linux-x64 build and win-x64 node.exe from nodejs.org/dist (each checked against SHASUMS256.txt) and runs --build-sea on ubuntu. The zip joins SHA256SUMS, the provenance attestation, the release assets and the dry run's artifact. Nothing else in the job changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… releases (#96) The existing Windows job builds the exe from the checkout and runs scripts/check-exe.ps1 from Windows PowerShell 5.1: --version against package.json, an unknown section refused with the exe's download advice, an azure pin passing with az absent (PATH is System32), the arguments a&b, %PATH%, ^ and a|b reaching explain --json unchanged, and controls that must fail (a wrong pin against a fake az, a damaged exe copy). The job's timeout goes from 8 to 10 minutes. The changed job (ubuntu, daily) asks build-exe.mjs for a newer security release of the pinned Node line and opens one issue per release, with issues: write on that job only; a failure there never skips the tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
README's Windows install part says each release from 1.3.0 has the exe zip and that winget comes with 1.3.0; CHANGELOG under Unreleased; AGENTS.md's layout table names src/version.ts and the exe scripts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
) The multi-file manifest winget-pkgs requires (version, installer, defaultLocale en-US), schema 1.28.0 with the yaml-language-server headers real manifests carry. The installer is the release's cloudpin-X.Y.Z-win-x64.zip, a zip with one portable nested installer, cloudpin.exe, aliased as cloudpin. ArchiveBinariesDependOnPath is left unset: the exe carries everything it needs, so winget's default link in its Links folder is enough, and install-method.ts already recognises it. __VERSION__, __SHA256__ and __RELEASE_DATE__ are filled in by scripts/bump-installers.mjs --winget. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
) --winget <out-dir> fills packaging/winget/'s templates and writes them to <out-dir>/manifests/p/paureis/cloudpin/<version>/, winget-pkgs' layout, so wingetcreate submit takes that folder. InstallerSha256 is the SHA256SUMS line for cloudpin-X.Y.Z-win-x64.zip, uppercase as winget-pkgs writes it, after the downloaded zip is checked against it. ReleaseDate is the GitHub Release's published date from the public API, or --date YYYY-MM-DD. Each rendered file must parse as YAML for paureis.cloudpin at that version with no placeholder left. As with --tap and --bucket, every check runs before any write, and the options combine: a version folder that already has files is refused before anything is downloaded (--force rewrites it), and a wrong exe zip leaves the bucket untouched too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Numbered by-hand steps, the same for the first version and every later one: render with bump-installers --winget and winget validate, a classic public_repo token with a 7-day expiry, read into WINGET_CREATE_GITHUB_TOKEN with Read-Host so it never appears on a command line (wingetcreate reads that variable when no --token is given), wingetcreate submit with the PR titles winget-pkgs' template asks for, then the CLA bot, the validation labels, and what to do on Binary-Validation-Error, Defender and executable failures, with the signing options from the design. Later versions use submit, not update, so the submitted manifest is the one checked against SHA256SUMS. Points not confirmed by the docs are marked unverified. AGENTS.md's layout table names packaging/winget/ and this page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…#96) Bun has no node:sea and refuses to load a module that imports it, so under Bun every cloudpin command exited 1, the shell wrapper's cloudpin exec crashed and agent hooks failed open. isSea() now asks process.getBuiltinModule, and is false when the module or the function is missing (Node before 22.3) or the lookup throws. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The index.json fetch had no timeout, so a stalled nodejs.org ran into the Nightly job's own limit and cancelled it. securityRelease() now aborts the request after 20 s with an error that names the URL. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
It shared the changed job, so a stalled nodejs.org could cancel that job and skip the tests that need it, and the job held issues: write. Now node-security runs daily on its own with issues: write, nothing needs it, and changed is back to contents: read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The duplicate check listed only open issues, so closing "Node X security release: rebuild cloudpin.exe?" as not needed filed it again the next day, and every day until the pin moved. It now lists all states. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The win-x64 node.exe and the linux-x64 tarball were checked only against SHASUMS256.txt from the same host, so a file swapped on nodejs.org along with its SHASUMS256.txt would pass. scripts/exe-node-sha256.txt now records both for the pinned 26.12.0 (cross-checked against the signed SHASUMS256.txt.asc), and a download is used only when it matches the record and SHASUMS256.txt; any mismatch or missing record fails the build. Bumping the pin is one step: the version, then --print-hashes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Submitting row still said wingetcreate update per minor release; docs/winget.md submits the rendered, SHA256SUMS-checked manifest with wingetcreate submit every time, because update hashes the zip itself. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The damaged-copy control looked for the static node:sea import, which the Bun fix removed, so Nightly's Windows job failed "the bundled code is in the exe" (run 39105515088; the other 11 checks passed). It now looks for process.getBuiltinModule?.(id), a code token found once in the bundle, so damaging it is still a syntax error. All 12 checks pass on the exe the post-fix release dry run built (run 39105516712). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
|
Branch runs after the review fixes: release dry run 39105516712 green (pinned-hash build). Nightly 39105515088: node-security and ubuntu green; on Windows the exe built and passed 11/12 checks. The 12th, the damaged-copy control, was looking for the node:sea import that the Bun fix removed. Fixed in 9ca4628, and all 12 checks now pass locally on the post-fix CI-built exe. The Windows job will be confirmed by a re-dispatch next session. |
CHANGELOG: main's, with the winget lines under [Unreleased]. Lockfile: main's entries; rolldown is now a direct devDependency at 1.2.15, the version vitest already brings, so only one copy is installed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
26.12.1 was a security release after the 26.12.0 this branch pinned. The recorded hashes match the release's SHASUMS256.txt.asc, whose signature checks out against the signer's key from nodejs/release-keys. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
paureis
marked this pull request as ready for review
November 4, 2026 23:21
Bundled comments mention package.json (a Vercel source path, npm's engines), so Nightly's exe build stopped once main was merged. The check now looks for the name as a string, in any quotes and through a path. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #96.
A standalone
cloudpin.exefor winget: a Node 26 single executable application with cloudpin,yamlandcross-spawnbundled inside. The design isdocs/superpowers/specs/2026-10-18-winget-design.md(owner-approved).In this PR
scripts/build-exe.mjs:dist/cli.jsinto one ESM file with rolldown. rolldown is a new devDependency pinned to 1.2.15, the version vitest already brings.src/version.tsreads package.json everywhere except inside the exe.node --build-seawith the Node pinned inscripts/exe-node-version.txt(26.13.0 since the merge with main), with code cache and snapshot off.scripts/exe-node-sha256.txtand againstSHASUMS256.txt.cloudpin.exewith LICENSE.cloudpin-X.Y.Z-win-x64.zipin the existing ubuntu job (a cross-build, no Windows minutes). It's added toSHA256SUMS, the attestation, the release assets and the dry-run artifact.node:seathroughprocess.getBuiltinModule, so Bun still runs the npm build.winget upgrade paureis.cloudpin.scripts/check-exe.ps1: version, refusals, an az-absent pin, arguments cmd.exe would re-parse, and controls that must fail.node-securityjob (issues: writeonly there) files one issue per newer Node 26 security release. It checks--state allbefore filing, and its fetch has a 20 s timeout.packaging/winget/(paureis.cloudpin, publisherpaureis, schema 1.28.0).bump-installers.mjs --winget <dir>renders them from the release'sSHA256SUMSafter checking the zip.wingetcreate submitand the token in an environment variable, never on the command line. README, CHANGELOG (Unreleased) and AGENTS.md are updated too.Evidence
npm run typecheckexit 0;npm test1039 passed, 8 skipped (Windows).bun dist/cli.js --versionprints 1.1.0. The control: under Bun,import("node:sea")throws.check-exe.ps1checks on Windows, controls included (a wrong pin, a blockedexec, a damaged copy). Microsoft Defender found no threats in the exe or the zip.--versionmedian startup 46 ms, against 103 ms fornode dist/cli.json Node 22.winget validate(v1.29) passes on a rendered set. DroppingInstallerSha256orLicensemakes it fail.Review
One review round. The must-fix: a static
node:seaimport broke cloudpin under Bun. Fixed if cheap:Left:
--locationinstall reads as the plain exe.🤖 Generated with Claude Code