Skip to content

fix(container-runtime): drop prettier from the build script#3467

Merged
dr-bonez merged 1 commit into
masterfrom
fix/container-runtime-build-prettier-churn
Jul 14, 2026
Merged

fix(container-runtime): drop prettier from the build script#3467
dr-bonez merged 1 commit into
masterfrom
fix/container-runtime-build-prettier-churn

Conversation

@dr-bonez

Copy link
Copy Markdown
Member

Problem

Every StartOS build was rewriting container-runtime/src/**/__fixtures__/*.ts from double quotes to single quotes.

Root cause: the container-runtime build script ran prettier . --write from inside the project directory. Since #3437 removed the local prettier config, that invocation resolves the root .prettierrc.json (config files walk up the tree) but not the root .prettierignore (ignore files only resolve from the cwd) — so the **/__fixtures__/ protection never applied. Verified with prettier --file-info: the same fixture file reports ignored: false from the project cwd and ignored: true from the repo root.

make start-os-format/-check had the same bug via the local format/format:check npm scripts.

Fix

  • build script is now just rm -rf dist && tsc; the local format/format:check scripts and the prettier devDependency are removed — one root prettier config, no per-component prettier surface.
  • start-os-format/start-os-format-check are Rust-only, matching start-wrt/start-tunnel; TS formatting for web + container-runtime runs through web-format (root cwd, so the ignore applies).
  • Updated the docs that still described the pre-chore(fmt): normalize formatting — one config per language, reproducible rustfmt #3437 setup (local config, double quotes, build-time formatting) in projects/start-os/{AGENTS,CONTRIBUTING}.md and container-runtime/{AGENTS,CONTRIBUTING}.md.
  • Lockfile regenerated with pinned npm 11.13.0: drops prettier and syncs the file: SDK dist entry to 2.0.3 (matches the SDK version at HEAD).

No changelog entry — build tooling only, nothing user-visible.

Verification

  • npm run build exits 0 and leaves the tree untouched (fixtures stay double-quoted)
  • npx prettier --check from the root passes over container-runtime and the edited docs
  • container-runtime jest suite: 12 tests, 6 snapshots, all pass
  • make -n start-os-format start-os-format-check parses and shows the expected Rust-only recipes

Since #3437 removed the local prettier config, prettier invoked from
inside container-runtime resolves the root .prettierrc.json (config
files walk up) but not the root .prettierignore (ignore files resolve
from the cwd), so every build rewrote the __fixtures__/ files the
ignore protects. Remove the prettier --write from the build script,
the local format scripts, and the prettier devDependency; formatting
runs through web-format from the repo root instead. Make
start-os-format Rust-only to match the other products, update the
docs that still described the pre-#3437 double-quote config, and sync
the lockfile's SDK dist version to 2.0.3.
@dr-bonez dr-bonez requested a review from MattDHill July 13, 2026 23:55
@dr-bonez dr-bonez merged commit 170e46f into master Jul 14, 2026
9 checks passed
@dr-bonez dr-bonez deleted the fix/container-runtime-build-prettier-churn branch July 14, 2026 00:22
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.

2 participants