Skip to content

Release | Pack a minimized dist.tar.gz - #24

Merged
BrianGenisio merged 1 commit into
mainfrom
pack-minimized-release-dist
Oct 1, 2026
Merged

BrianGenisio merged 1 commit into
mainfrom
pack-minimized-release-dist

Conversation

@BrianGenisio

@BrianGenisio BrianGenisio commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Release archives used to ship the whole checkout plus node_modules, which made dist.tar.gz huge. This mirrors the email-simulator pack flow so releases are a small, runnable tree with no node_modules.

Changes

npm run pack (scripts/pack-dist.mjs) minifies the client, bundles the server (Express + LLM SDKs inlined), copies static assets / design-system / examples, smoke-tests /api/session-config against the packed app, then writes dist.tar.gz.

The release workflow now runs tests and npm run pack instead of tarring the repo. Locally this produced a ~1.4 MB archive vs ~43.3 MB, which expands into 4.4MB vs 175MB. So the unpack/run speed will be much faster with this change.

Worth a close look: the packed server resolves import.meta.url to dist/, so eval-system-prompt.md is copied next to server.js (not under lib/).

Testing

  • npm run pack succeeds and prints size breakdown
  • Unpacked dist.tar.gz and confirmed GET /api/session-config returns 200
  • Create a GitHub release and confirm the uploaded asset is the new small tarball

Match the email-simulator approach: bundle client and server with esbuild so releases ship without node_modules.

Co-authored-by: Cursor <cursoragent@cursor.com>
@BrianGenisio
BrianGenisio marked this pull request as ready for review October 1, 2026 15:37
@coderabbitai

coderabbitai Bot commented Oct 1, 2026

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Essentials

Run ID: 2b5dbb5d-9e00-4c96-a0f3-faaa80e1f4ce

📥 Commits

Reviewing files that changed from the base of the PR and between adc784a and 27d3026.

📒 Files selected for processing (5)
  • .github/workflows/release.yml
  • .gitignore
  • README.md
  • package.json
  • scripts/pack-dist.mjs

Included review availability: This review used your included allowance. 4 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.


📝 Walkthrough

Walkthrough

The release workflow now runs npm test and npm run pack. The packaging script builds client and server bundles, copies release assets, checks the bundled server’s /api/session-config endpoint, and creates dist.tar.gz. The README documents the packaging command and runtime setup.

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to 27d30

The packaging and release configuration align with the documented standalone runtime. No actionable merge-blocking issue was found; normal build and release checks remain appropriate.

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: packaging a minimized dist.tar.gz release archive.
Description check ✅ Passed The description directly explains the new packaging flow, workflow changes, archive size reduction, and testing status.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Comment @coderabbitai help to get the list of available commands.

@BrianGenisio
BrianGenisio merged commit ff6527d into main Oct 1, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant