docs: add monorepo development workflow documentation
- Update root dev script to build packages before watching - Add --no-dts flag to package dev scripts to avoid DTS race conditions - Document monorepo development workflow in README Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
c728a80a9b
commit
e87e39f13b
5 changed files with 19 additions and 4 deletions
15
README.md
15
README.md
|
|
@ -53,6 +53,21 @@ pnpm dev:all # Start both Gateway and Web app
|
|||
|
||||
The Desktop app runs a standalone Hub with embedded Agent Engine - no Gateway required for local use.
|
||||
|
||||
### Monorepo Development
|
||||
|
||||
| Command | Purpose |
|
||||
|---------|---------|
|
||||
| `pnpm dev` | Full dev mode — watches `core`, `types`, `utils` packages |
|
||||
| `pnpm dev:desktop` | Desktop only — skip package watching |
|
||||
|
||||
**When modifying packages:**
|
||||
|
||||
1. Edit code in `packages/core`, `packages/types`, or `packages/utils`
|
||||
2. Terminal shows `[core] ESM ⚡️ Build success` (~100ms)
|
||||
3. Restart Desktop to apply changes (Ctrl+C, then `pnpm dev`)
|
||||
|
||||
> **Why restart?** Electron main process does not support hot reload — this is an Electron limitation, not ours.
|
||||
|
||||
### Credentials
|
||||
|
||||
```bash
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
"scripts": {
|
||||
"multica": "pnpm --filter @multica/cli dev",
|
||||
"mu": "pnpm --filter @multica/cli dev",
|
||||
"dev": "GATEWAY_URL=https://multica-dev.copilothub.ai/ pnpm --filter @multica/desktop dev",
|
||||
"dev": "turbo build --filter=@multica/types --filter=@multica/utils --filter=@multica/core && concurrently -n types,utils,core,desktop -c blue,green,yellow,cyan \"pnpm --filter @multica/types dev\" \"pnpm --filter @multica/utils dev\" \"pnpm --filter @multica/core dev\" \"GATEWAY_URL=https://multica-dev.copilothub.ai/ pnpm --filter @multica/desktop dev\"",
|
||||
"dev:desktop": "GATEWAY_URL=https://multica-dev.copilothub.ai/ pnpm --filter @multica/desktop dev",
|
||||
"dev:desktop:reset": "rm -rf ~/.super-multica && echo '✓ Deleted ~/.super-multica - Fresh install state restored'",
|
||||
"dev:desktop:fresh": "pnpm dev:desktop:reset && pnpm dev:desktop",
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@
|
|||
"files": ["dist"],
|
||||
"scripts": {
|
||||
"build": "tsup",
|
||||
"dev": "tsup --watch",
|
||||
"dev": "tsup --watch --no-dts",
|
||||
"typecheck": "tsc --noEmit",
|
||||
"test": "vitest run",
|
||||
"test:watch": "vitest"
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
"files": ["dist"],
|
||||
"scripts": {
|
||||
"build": "tsup",
|
||||
"dev": "tsup --watch",
|
||||
"dev": "tsup --watch --no-dts",
|
||||
"typecheck": "tsc --noEmit"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
"files": ["dist"],
|
||||
"scripts": {
|
||||
"build": "tsup",
|
||||
"dev": "tsup --watch",
|
||||
"dev": "tsup --watch --no-dts",
|
||||
"typecheck": "tsc --noEmit"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue