@houserules/plugin-changesets
v0.2.2
Published
houserules plugin: changesets integration (canonical changelog) and the optional per-commit changelog ledger.
Maintainers
Readme
@houserules/plugin-changesets
An agent that finishes a change and stops there leaves nothing behind for the next release. Nobody remembers three weeks later which package a fix touched or what to write in the changelog, and by then the diff is gone from context too.
This plugin wires changesets into the agent's own workflow: a script that authors a changeset
the same way changeset add would, a skill and an agent that do it after a completed change,
and a Stop hook that nudges when package source changed with no changeset alongside it.
Install
pnpm add -D @houserules/plugin-changesets
pnpm exec houserules initRequires @houserules/cli.
init is what writes the modules into .claude/. The changesets module is on by default in
a monorepo, or when .changeset/ already exists.
Modules
changesetsinstallschangeset-write.mjs, a non-interactive changeset author for agents. It validates package names against the actual workspace, then writes through the repo's own@changesets/write, the same writerchangeset adduses. That library is required: if it is not resolvable from the repo root, the script exits with the install command instead of hand-rolling a file.--emptyrecords "no release needed", and--absorbfolds one or more pending changesets into an amended one.It also installs
changeset-check.mjs, a Stop hook that nudges when package source changed with no changeset recorded for it. The hook exits 2 on purpose when it fires: a non-zero exit is how a Stop hook tells Claude Code to keep going rather than end the turn, so the agent sees the nudge and can act on it in the same turn instead of losing the context. Every other path, including any internal failure, exits 0, so the hook can never break a session. It seeds.changeset/config.jsonwhen the repo has none, and writes the/changesetskill plus thechangeset-condenseskill and thechangeset-writeragent (haiku).If
.changeset/config.jsonis missing after install, or@changesets/cliis not a devDependency,houserules doctorreports it.ledgeris optional and off by default. It installspackage-changelog.mjs, which writes a per-commit JSONL changelog to.claude/changelogs/, plus a template for instantiating an archivist agent per target. It exists for repos that want commit-granular history alongside changesets, not instead of them..claude/changelogs/never collides with theCHANGELOG.mdthatchangeset versionowns, because changesets is still the canonical changelog. See@houserules/cli's README for why.
Upgrading from the CLI core
changesets and ledger were built-in CLI modules. A repo that recorded either before the
split gets a HouseError on its next init or update naming this package. Installing it and
adding it to the plugins array in .claude/houserules.config.json restores both modules and their
files. Nothing is deleted in the meantime.
Part of houserules
houserules is a portable set of Claude Code infrastructure that keeps the agent's context lean. This is one of twelve first-party plugins. The package list has the rest.
License
MIT. See LICENSE.
