Add a CLI command that scans a directory containing agent instruction files and…
- User
Add a CLI command that scans a directory containing agent instruction files and generates an
inception.jsonmanifest for `it. Use existing limbo directory as a starting point Assistant
Now let me read the key source files before implementing.
Assistant
Let me check the test structure and existing limbo contents quickly.
Assistant
Now I have everything I need. Let me implement the
initcommand.Assistant
Now update
index.tsto add theinitcommand:Assistant
Now update
parseCLIto handleinitand--force:Assistant
Also update the no-args early return to include
force:Assistant
Now wire up
initinmain():Assistant
Now add tests for the
initcommand:Assistant
Two lint issues to fix: template literal and cognitive complexity. Let me refactor:
Assistant
The
readdirreturn type needs an explicit buffer encoding hint. Let me fix:Assistant
Clean. Let me run the tests to confirm everything works:
Assistant
The dry-run test assertion is wrong —
assert.throwsdoesn't work with async imports. Let me fix it:Assistant
All 15 tests pass. Final fmt/lint check:
Assistant
Done. Here's what was added:
inception-engine init <directory> [options]Recursively scans
<directory>for subdirectories containing aSKILL.mdfile and writes aninception.jsonmanifest targeting all agents by default.Key behaviors:
- Skips directories whose name isn't a valid skill name (warns instead of failing)
- Resolves basename collisions by deriving a name from the relative path (e.g.
skills/foo→skills-foo) - Refuses to overwrite an existing
inception.jsonunless--forceis passed --dry-runprints what would be written without touching the filesystem--agentsrestricts the agent list in the generated manifest
Files changed:
src/core/init.ts— new scanning and generation logicsrc/index.ts— wired up the command, added--forceflag, updated usagesrc/types.ts— added"init"to command union,forcefield toCliOptionstest/unit/cli.test.ts— 6 new tests covering the happy path and edge cases
- User
commit your changes
Assistant
Committed as
6b8e804.