Repository navigation
v6.14.0-beta.3
Pre-release
Pre-release
·
206 commits
to main
since this release
Pre-release — install with
npm install -g universal-dev-standards@beta. What to test and how to go back to stable: docs/PRE-RELEASE.md.Existing adopters — run
uds updateonce. The pre-commit hook thatuds initwrote in earlier versions is the single linenpx uds check, which can ask npm for a package namedudsthat is not this project. New installs no longer write it, anduds updatereplaces the line UDS itself wrote in an existing.husky/pre-commit. Also new:uds uninstallremoves only what it can prove UDS wrote (a project installed by an earlier UDS keeps some files, and says why), anduds open-work next-actionreads a next action written as a table column.
Changed
uds open-work next-actionnow reads a next action written as a Markdown table column, not only as a heading or an inline label. A column whose header is in the next-action vocabulary (Next action,Next step,下一步,下一動, and now回來要做什麼) is read on every row, and each report carries the line number and the row's first cell. The vocabulary is still one list: headings, inline labels and table headers all read it. A table inside a blockquote (> | … |) is now seen, and a|inside a code span or after a backslash no longer splits a cell. A row whose cell count differs from its header is listed asUNDECIDABLEand never read as empty; with no violation elsewhere the exit code is 2, because a clean result would cover only part of the field. An empty,—or-cell is counted and not evaluated, and is not an OWT-019 violation. Found while measuring the DEC-122 H2 baseline on a real work log, where 32 of 80 rows had a different cell count than their header.回來要做什麼is the header that work log actually uses (its prose calls the column 下一動) and is UNCALIBRATED (OWT-016). The check's own mutation tests gain eight table mutants; the previous seventeen still go red.
Fixed
uds uninstallno longer leaves UDS's own files behind, and no longer removes what it cannot prove is UDS's. Afterinit→update --with-hooks→uninstall -yit reported "Removed 5, Skipped 1, Errors 0" and left 15 hook scripts underscripts/hooks/, an empty.codex/, an AGENTS.md whose generated header still pointed at the deleted.standards/, and the body of.git/hooks/pre-committhatuds inithad written. The rule is now: a whole file is deleted only if the manifest records that UDS wrote it (installedArtifacts, written byinitandupdate --with-hooks) and its content still matches the recorded hash. Anything else is kept, and the output says why (kept: modified since UDS wrote it,kept: no install record — installed by an older UDS or not by UDS, so UDS cannot prove it wrote this). Folders are removed only if UDS created them and they are now empty; the adopter's ownscripts/hooks/*.mjs,.agents/rules/*and hook entries are kept. A project installed by an earlier UDS has no records, so its scripts, generated AGENTS.md text and native pre-commit body are kept and explained rather than guessed at. Every "Removed" line now corresponds to a real deletion or edit, and a run that ends with errors exits non-zero.uds uninstallno longer draws a prompt or a stack trace when nobody can answer, and no longer exits 0 when it did nothing.--dry-runnever prompts (it writes nothing) and previews every category. Without--yesand without a terminal, a real run refuses with exit code 2 instead of assuming "yes"; a closed prompt exits 130; an uninitialized project exits 1.uds init --with-hooksno longer prints'chmod' is not recognizedon Windows. The pre-commit hook was made executable withexecSync("chmod +x ...")inside a try/catch; the catch hid the failure from the code butexecSynchad already sent cmd.exe's error to the terminal. It now callsfs.chmodSyncand skips the step on Windows, where there is no execute bit.- Security: the pre-commit hook
uds initwrites no longer asks npm for a package nameduds, which is not this project. The hook was the single linenpx uds check.npxlooks innode_modules/.binand onPATHfirst and goes to the npm registry only when neither has it, and the registry packageudsis an unrelated project (maintainer wizawu,github.com/wizawu/uds, v0.3.6, last published 2022, nobintoday). On a machine with UDS installed nothing changed; on any clone without it the hook fetched a stranger's package by name — harmless only because that package has no executable yet, and the day it ships one every adopter's every commit would run it.--no-installis not a fix: measured against a local registry that logs every request (npm 10.9.9, 11.20.0, 12.1.0, identical),npx --no-install udsstill requestsGET /uds, andnpx --no-install --package=universal-dev-standards udscannot find a global install at all. The hook now uses neither: it looks foruniversal-dev-standards(the package's own name, which only this project can publish) in the project'snode_modules/.binand then onPATH, runscheck, and when it is found nowhere prints what to install and exits non-zero — it neither skips the check nor downloads anything, and a failing check stops the commit even when the adopter's own commands follow it.uds uninstallremoves the new block whole, by its markers. The human-readable text has the same fix: the warning line inside generatedCLAUDE.md/AGENTS.mdblocks and the hook hints now saynpx universal-dev-standards init/update(the warning line is a few tokens longer, soscripts/prompt-footprint-baseline.jsonis raised by exactly the measured 3–6). Existing adopters:uds update(every mode except--skills,--commands,--integrations-only,--standards-onlyand--rollback, and--with-hooks;--planreports without writing) replaces the line UDS itself wrote in.husky/pre-commit— only the two exact shapes UDS has ever generated (npx uds check, and the oldernpx uds check --standard checkin-standards) directly under its# UDS Standard Checkmarker — and a line you wrote or edited yourself is left alone and reported with its line number. It runs before the "already up to date" return, so an adopter whose standards are current gets it too.uds checknow warns about a hook that still runs the bare name. A new test walks everythingnpm packships and fails on any string that runs the bareudsthrough a package runner (npx, bunx, pnpm dlx, yarn dlx, npm exec); the non-Node native hook (uds check, resolved fromPATHonly, never a registry) was not affected and is unchanged.