Просмотр исходного кода

docs: add instructions for running web and desktop apps during development

Aiden Cline 3 месяцев назад
Родитель
Сommit
1d54f90330
1 измененных файлов с 23 добавлено и 0 удалено
  1. 23 0
      CONTRIBUTING.md

+ 23 - 0
CONTRIBUTING.md

@@ -67,8 +67,31 @@ Replace `<platform>` with your platform (e.g., `darwin-arm64`, `linux-x64`).
 - Core pieces:
 - Core pieces:
   - `packages/opencode`: OpenCode core business logic & server.
   - `packages/opencode`: OpenCode core business logic & server.
   - `packages/opencode/src/cli/cmd/tui/`: The TUI code, written in SolidJS with [opentui](https://github.com/sst/opentui)
   - `packages/opencode/src/cli/cmd/tui/`: The TUI code, written in SolidJS with [opentui](https://github.com/sst/opentui)
+  - `packages/app`: The shared web UI components, written in SolidJS
+  - `packages/desktop`: The native desktop app, built with Tauri (wraps `packages/app`)
   - `packages/plugin`: Source for `@opencode-ai/plugin`
   - `packages/plugin`: Source for `@opencode-ai/plugin`
 
 
+### Running the Web App
+
+To test UI changes during development, run the web app:
+
+```bash
+bun run --cwd packages/app dev
+```
+
+This starts a local dev server at http://localhost:5173 (or similar port shown in output). Most UI changes can be tested here.
+
+### Running the Desktop App
+
+The desktop app is a native Tauri application that wraps the web UI. To run it:
+
+```bash
+bun run --cwd packages/desktop dev
+```
+
+> [!NOTE]
+> Running the desktop app requires additional Tauri dependencies (Rust toolchain, platform-specific libraries). See the [Tauri prerequisites](https://v2.tauri.app/start/prerequisites/) for setup instructions.
+
 > [!NOTE]
 > [!NOTE]
 > If you make changes to the API or SDK (e.g. `packages/opencode/src/server/server.ts`), run `./script/generate.ts` to regenerate the SDK and related files.
 > If you make changes to the API or SDK (e.g. `packages/opencode/src/server/server.ts`), run `./script/generate.ts` to regenerate the SDK and related files.