Make the clipboard skill installer check target hub.ts compatibility and required assets before copying files. Previously, an unsupported hub layout caused installation to fail only after it had already copied files into the target checkout, leaving partial changes.
Changes
Verify hub exists and contains both expected injection anchors (unless already patched).
Verify all source assets exist before target writes.
Reuse the preflight-read hub content when applying the patch.
Add an isolated Node.js test using a fake incompatible checkout to assert no clipboard directory remains.
Validation
node --test tests/*.test.mjs — 1 passed.
node --check scripts/install.mjs and git diff --check — passed.
No dependencies added; normal successful install flow is unchanged.
Summary
Make the clipboard skill installer check target
hub.tscompatibility and required assets before copying files. Previously, an unsupported hub layout caused installation to fail only after it had already copied files into the target checkout, leaving partial changes.Changes
Validation
node --test tests/*.test.mjs— 1 passed.node --check scripts/install.mjsandgit diff --check— passed.No dependencies added; normal successful install flow is unchanged.