mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-17 04:02:21 +00:00
docs(coding-agent): document bundling other pi packages with bundledDependencies
This commit is contained in:
parent
23fd73e558
commit
f63a353779
1 changed files with 30 additions and 1 deletions
|
|
@ -202,12 +202,41 @@ The pi manifest supports glob patterns and exclusions:
|
||||||
{
|
{
|
||||||
"pi": {
|
"pi": {
|
||||||
"extensions": ["./extensions", "!**/deprecated/*"],
|
"extensions": ["./extensions", "!**/deprecated/*"],
|
||||||
"skills": ["./skills", "./node_modules/other-pkg/skills", "!**/experimental/*"],
|
"skills": ["./skills", "!**/experimental/*"],
|
||||||
"themes": ["./themes/*.json"]
|
"themes": ["./themes/*.json"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
**Bundling other pi packages:**
|
||||||
|
|
||||||
|
To include resources from another pi package, add it as a dependency with `bundledDependencies` to ensure it's embedded in your published tarball:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"name": "my-extension-pack",
|
||||||
|
"dependencies": {
|
||||||
|
"other-pi-package": "^1.0.0"
|
||||||
|
},
|
||||||
|
"bundledDependencies": [
|
||||||
|
"other-pi-package"
|
||||||
|
],
|
||||||
|
"pi": {
|
||||||
|
"extensions": [
|
||||||
|
"./extensions",
|
||||||
|
"./node_modules/other-pi-package/extensions",
|
||||||
|
"!**/unwanted-extension.ts"
|
||||||
|
],
|
||||||
|
"skills": [
|
||||||
|
"./skills",
|
||||||
|
"./node_modules/other-pi-package/skills"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`bundledDependencies` embeds the package inside your tarball, preserving the `node_modules/` structure. Without it, npm's hoisting could move the dependency elsewhere, breaking the paths.
|
||||||
|
|
||||||
The `package.json` approach enables:
|
The `package.json` approach enables:
|
||||||
- Multiple extensions from one package
|
- Multiple extensions from one package
|
||||||
- Skills, prompts, and themes declared alongside extensions
|
- Skills, prompts, and themes declared alongside extensions
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue