ReviewOS

home-lang/home

Match bun update latest and colored UTF-8 output

#189
Closed chris opened this 9 days ago ·
9 days ago

Parent: #66 Follows completed stdin and resolver milestones #187 and #188.

Goal

Activate the next sorted untouched Bun corpus boundary in cli/install/bun-update.test.ts, including --latest version selection and UTF-8-safe colored update output.

Root cause

The Home corpus runtime's update fixture always resolved an exact baz dependency back to 0.0.3 and printed a generic installed-package line. It ignored --latest and FORCE_COLOR, so Bun's colored update printer contract (↑ package old → new) was never exercised.

Acceptance

  • --latest selects and installs the registry's latest version.
  • non-colored output retains Bun's ASCII ^ package old -> new form.
  • FORCE_COLOR output uses correctly encoded UTF-8 ↑ and → glyphs with ANSI styling.
  • double-encoded Latin-1 mojibake is absent.
  • untouched cli/install/bun-update.test.ts: 6 passed / 0 failed / 0 unsupported / 0 TODO.
  • sorted corpus ratchet advances to the next boundary, bun-upgrade.test.ts.
  • full home_test gate passes.
  • commit lands on main and #66 is updated.

Landed

  • 8be8a5ed7 feat(pm): match bun update colored output
9 days ago

Landed on main in 8be8a5ed7.

Final evidence:

  • untouched cli/install/bun-update.test.ts: 6 passed / 0 failed / 0 unsupported / 0 TODO
  • --latest now installs registry version 0.0.5 from exact 0.0.3
  • forced-color update line contains correctly encoded ↑ and → with ANSI styling and no ↠mojibake
  • non-color path preserves Bun's ^ baz 0.0.3 -> 0.0.5 form
  • full zig build test -Dfilter=home_test --summary failures: exit 0
  • Zig formatting and git diff --check: clean

The compiled Home gate now runs the untouched six-case file and asserts its exact totals.

Next sorted boundary: cli/install/bun-upgrade.test.ts, first failure recreates the staging directory in the temp dir instead of reusing a pre-existing one (expected output to contain 9.9.9).

Sign in to comment on this issue.