docs: add isolated dev command and usage [skip ci]
This commit is contained in:
@@ -133,6 +133,15 @@ For exact input/output and UX guarantees, see [`docs/contract.md`](docs/contract
|
||||
pi -e ./src/index.ts
|
||||
```
|
||||
|
||||
### Run in isolated test mode (extension + bundled skill only)
|
||||
|
||||
```bash
|
||||
pnpm dev
|
||||
pnpm dev ../test
|
||||
```
|
||||
|
||||
`pnpm dev [path]` runs pi with `--no-extensions --no-skills --no-prompt-templates --no-themes --no-context-files`, loads this repo’s extension and `skills/ask-user`, and sets the working directory to `[path]` (defaults to `.`).
|
||||
|
||||
### Install dependencies
|
||||
|
||||
```bash
|
||||
|
||||
@@ -13,6 +13,17 @@ This folder keeps only the documentation needed to understand and maintain the e
|
||||
- start with `contract.md` for behavior
|
||||
- read `architecture.md` for code layout
|
||||
|
||||
## Local test run
|
||||
|
||||
From repo root, run:
|
||||
|
||||
```bash
|
||||
pnpm dev
|
||||
pnpm dev ../some-target-folder
|
||||
```
|
||||
|
||||
This starts pi in isolated mode, loads only this extension and bundled `ask-user` skill, and uses the optional folder as `--cd` target.
|
||||
|
||||
## Rule of thumb
|
||||
|
||||
If a detail is about implementation mechanics, it should usually live in `src/` or `tests/`, not here.
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
"CHANGELOG.md"
|
||||
],
|
||||
"scripts": {
|
||||
"dev": "sh -c 'pi --no-extensions --no-skills --no-prompt-templates --no-themes --no-context-files -e ./src/index.ts --skill ./skills/ask-user --cd \"${1:-.}\"' --",
|
||||
"test": "node --test tests/*.test.ts",
|
||||
"typecheck": "tsc -p tsconfig.json",
|
||||
"format": "biome format --write .",
|
||||
|
||||
Reference in New Issue
Block a user