Migrate fjs/ci/nix to .f.mjs - #1493
Conversation
Updates the two dependents (fjs/ci, fjs/ci/node) to import runtime values from .f.mjs and types from types.ts separately, and fixes stale module.f.ts doc references including two with stale line-number citations.
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
functionalscript | a085863 | Commit Preview URL Branch Preview URL |
Aug 11 2026, 09:26 PM |
No local types to split; proof.f.ts migrates alongside it since its only dependencies (ci/common, asserts) are already migrated. Updates three dependents (ci, ci/nix's module and proof) and fixes stale module.f.ts doc references, including two with stale line-number citations.
proof.f.ts stays TypeScript for now: it has runtime dependencies on effects/node/virtual/module.f.ts and media/json/module.f.ts, both still unmigrated. Updates the fjs/module.f.ts dependent and fixes stale module.f.ts doc references across eight files, including one with a stale line-number citation. Verified npm run ci-update produces no drift in the generated workflow.
o2alexanderfedin
left a comment
There was a problem hiding this comment.
Approving. Reviewed at 5c07521 against main (caa5894). Three modules — fjs/ci, fjs/ci/nix, fjs/ci/node.
The generated CI workflow doesn't move
fjs/ci is the generator for this repo's own workflow, so behaviour preservation is checkable at the output rather than only at the source: I ran npm run ci-update on the branch and git status came back empty. The workflow the migrated generator produces is byte-for-byte what is committed.
Source-level equivalence
fjs/ci and fjs/ci/nix are token-identical to main's compiled output. fjs/ci/node differs by exactly one thing — a parameter rename inside the non-exported installNode (version → v) — which cannot be observed from outside the module.
The two changed declarations are both inert:
ci:({ nodeExtra }: Setup)→(setup: Setup)— parameter name only, same type.nodeMainSteps:typeof platformNodeSteps→(version: string) => readonly MetaStep[]. I checked these are the same type and they are:mainemitsplatformNodeSteps: (version: string) => readonly MetaStep[]andnodeMainSteps: typeof platformNodeSteps, so the branch just spells the expansion. Unlike an alias being dropped, nothing is orphaned here —typeofqueries a value, not a named type, andplatformNodeStepsis still exported and still referenced.
Everything else
npx tscclean; 2357 pass / 0 fail, matchingmain.- Public API: 0 removed, 0 added, and the two changed entries are the ones above.
- No
anyas a type in any emitted declaration. - Links 144/144, none added, 0 label/target mismatches.
- Both new
types.tsfiles keep their@moduleheader through emit. - CHANGELOG covers all three.
fjs/ciandfjs/ci/nixproofs correctly stay TypeScript — both importeffects/node/virtual/module.f.ts, still unmigrated.fjs/ci/node's proof had no such dependency and moved to.f.mjs, which is the right discrimination rather than a blanket rule.
Splits DetectState, DetectMeta, and the internal _Signature/_MagicState/ _Utf8Detect types into a sibling types.ts. proof.f.ts migrates alongside it since its own dependencies were already clean. Updates the sole external dependent (fjs/mcp/cas/module.f.ts) and the type-only import in fjs/media/module.f.ts, plus stale doc references and line-number citations across fjs/effects/todo, fjs/media/type/todo, fjs/media/todo/detect-cbor.md, and todo/plan/roadmap.md. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y9bV7Civ4LaC6GPsjcgnJY
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 23423a71b2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| /** | ||
| * Continuous integration helper commands for repository automation tasks. | ||
| * | ||
| * See `./types.ts` for the `Setup` type-level API. |
There was a problem hiding this comment.
Update stale CI module paths in the README
After these modules move to .f.mjs and Setup moves to types.ts, fjs/ci/README.md:10-22,45-46 still directs readers to the deleted module.f.ts, node/module.f.ts, and nix/module.f.ts files and omits the new type companion. Anyone following the repository's primary CI documentation therefore reaches nonexistent paths; update those entries as part of the migration.
Useful? React with 👍 / 👎.
module.f.ts, node/module.f.ts, and nix/module.f.ts were renamed to .f.mjs in this PR; the README's Files section and the "Generated Nix environments" section still pointed at the deleted paths. Flagged by Codex review. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y9bV7Civ4LaC6GPsjcgnJY
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
fjs/ci/nix/module.f.tsfrom authored TypeScript to JSDoc-typed.f.mjs, pertodo/migrate-typescript-to-mjs.md.NixJobtype into a siblingtypes.ts.proof.f.tsstays TypeScript for now — it has runtime dependencies oneffects/node/virtual/module.f.tsandci/node/module.f.ts, both still unmigrated.fjs/ci,fjs/ci/node) to import runtime values from.f.mjsand types fromtypes.tsseparately, and fixes stalemodule.f.tsdoc references across three files, including two with stale line-number citations.Test plan
npx tsc --noEmitcleannode ./fjs/module.ts t— 2357/2357 passGenerated by Claude Code