Files
openhuman/docs/src-tauri
M3gA-Mind 91e92cb98a fix(tauri): restore working tray controls in desktop shell
Implement tray icon setup directly in app/src-tauri with open/quit actions and daemon-safe window restore flow, plus tray behavior docs updates. Closes #93.

Made-with: Cursor
2026-03-31 22:17:00 +05:30
..

Tauri shell documentation (app/src-tauri/)

This folder is the desktop host for OpenHuman: Tauri v2 + WebView, IPC commands, window management, and bridging to the openhuman Rust sidecar (core JSON-RPC). It does not duplicate the full domain stack — that lives in the repo-root Rust crate (openhuman_core, src/bin/openhuman.rs).

Quick reference

Document Description
Architecture Modules, core process, sidecar staging
IPC commands invoke commands registered in lib.rs
Core bridge core_process, core_rpc, daemon helpers

Responsibilities

  1. Web UI — Load the Vite build from app/dist (or dev server on port 1420).
  2. IPC — Expose a small, explicit set of Tauri commands (see 02-commands.md).
  3. Core lifecycle — Ensure the openhuman binary is running (child process and/or service) and proxy JSON-RPC via core_rpc_relay.
  4. AI prompts on disk — Resolve bundled src/openhuman/agent/prompts from resources / dev cwd for ai_get_config / write_ai_config_file.
  5. Window + tray — Desktop window behavior and system tray (see lib.rs).

Building the sidecar

app/package.json core:stage runs scripts/stage-core-sidecar.mjs, which cargo build --bin openhuman at the repo root and copies the binary into app/src-tauri/binaries/ for Tauri externalBin.