by lunox-work
Carve a slice out of a TypeScript repository: the files a change needs, with the rest stubbed and mocked, so the folder installs, builds and tests on its own.
# Add to your Claude Code skills
git clone https://github.com/lunox-work/carveoutcarveout is an open-source testing skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by lunox-work. Carve a slice out of a TypeScript repository: the files a change needs, with the rest stubbed and mocked, so the folder installs, builds and tests on its own. It has 0 GitHub stars.
carveout's catalog security scan is still queued. You can run an instant dependency and prompt-injection check now with the "Scan for vulnerabilities" button above.
Clone the repository with "git clone https://github.com/lunox-work/carveout" and add it to your Claude Code skills directory (see the Installation section above).
carveout is primarily written in TypeScript. It is open-source under lunox-work on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other Testing skills you can browse and compare side by side. Open the Testing category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh carveout against similar tools.
No comments yet. Be the first to share your thoughts!
Available after the catalog security scan passes.
⚠️ Third-Party Software Notice
This skill is third-party open-source software developed and hosted independently on GitHub. SkillsLLM is an informational directory and does not control or maintain the underlying repository.
Any security checks, ratings, or warnings displayed by SkillsLLM are automated and limited in scope. They do not constitute a security certification or guarantee that the software is safe, error-free, or free from malicious code, vulnerabilities, compromised dependencies, or prompt-injection risks.
Review the source code, permissions, dependencies, and configuration before installing or running any third-party skill. Use is at your own risk. To the maximum extent permitted by applicable law, SkillsLLM is not liable for losses arising from third-party software.
The deep catalog scan for this skill is still queued. Run an instant dependency check now instead.
Named for the corporate carve-out: one unit split off from a company so it can stand on its own. carveout does that for one feature of a repository, and takes the work back when it is done.
$ git clone git@github.com:acme/closed-repo
709 files · 245,456 lines of TypeScript
every package, infra/, .github/workflows/
their branch runs CI with your secrets
$ carveout handoff \
packages/jira/src/selection-jql.ts
Verdict: ready: it installs, builds, and its
tests pass before any edit
Tests: 15 of 15 test(s) pass before any edit
Shows 15 files, 2,980 lines
Names: 3 rename(s) hide the repository's
$ carveout patch ../returned --output change.patch
carveout: 2 changed, 0 new and 0 deleted files
$ git apply change.patch && npm test -w packages/jira
ℹ tests 165
ℹ pass 165
ℹ fail 0
$ carveout patch ../returned
carveout: kept out:
packages/jira/src/selection-jql.ts,
could pass a test without the code
passing it (process.execArgv matched
against a test runner)
exit 6
Same task. 15 files out of 709. The shortcut held before anything ran it.
A real hand-off on sandbox-factory,
2026-11-11. The 15 files are the entry point, its test, and 13 pure modules
copied so that test runs on real code. Everything else the slice touches is
a .d.ts stub with a recording mock: declarations, never bodies. Those 13
modules were pricing code. plan lists every copied file before anything is
written, and --private keeps a folder out: here that shows 245 lines, and 7
tests then fail on the mocks before any edit. You choose.
npx skills add lunox-work/carveout -g
In Claude Code, the repository is also a plugin marketplace:
/plugin marketplace add lunox-work/carveout, then
/plugin install carveout@carveout. It holds two skills:
carveout, the hand-off, and
carveout-gate, impact and gate for a
change made in the repository.
Then ask your coding agent (Claude Code, Codex, Cursor, or any agent that
loads skills): "hand src/billing to a contractor". It plans the slice,
shows you what goes out, and cuts it once you agree. Without a skill, use the
CLI:
npx -y carveout handoff src/billing/quote.ts --task task.md --out ../quote-slice
Needs Node 22.12+ and a TypeScript repository (npm, pnpm or Yarn; node:test
or Vitest). Code that came back runs only in Docker; without it, carveout
runs none of it unless you pass --no-sandbox.
# maintainer, at the repository's root
npx -y carveout plan apps/api/src/billing --depth 1 --with-tests # what the folder would hold; writes nothing
npx -y carveout handoff apps/api/src/billing --task task.md --out ../billing-slice
# contractor: npm ci, edit, npm test, send the folder back
# maintainer, on the folder that came back
npx -y carveout patch ../billing-slice --output billing.patch # runs none of its code
less billing.patch # read all of it
git switch -c contrib/billing && git apply --3way billing.patch # then a PR: CI decides
.d.ts stub with a recording mock, so the
folder installs, builds and tests on its own.LunoxCart becomes AcmeCart). Only your receipt maps them back, and it
never leaves your machine.check runs the folder as the contractor will.
It says the folder is ready (its tests pass before any edit) or names the
tests that fail on the mocks and what would run them on real code.carveout patch turns the folder's edits into a patch in your
names. It trusts nothing in the folder: the receipt decides what a patch
may carry. It runs none of their code.| Comes back | Held, named, exit 6 until you --allow it |
|---|---|
| Edits to the slice's files | CI workflows, hooks, Dockerfiles, Makefiles, .env*, manifests, lockfiles |
| New files in the slice's packages | Deleted tests, and tests that lose, move or rewrite an assertion |
| New tests, where the package's runner finds them | .skip, .only, and code that spots a test run (NODE_ENV, argv, stack) |
| A package you add, named with its pin | New reach: disk, network, process, environment, eval, a missing package |
| Your names, put back | New @ts-ignore or eslint-disable, and files in other packages |
The policy reads syntax, not intent: code that special-cases a test's own inputs passes it. Read the whole patch before anything runs it, and run its first CI with no secrets. The full policy is in the reference.
git apply --3way.