Aidget is a cross-platform desktop widget host built with Rust/Tauri 2 and
TypeScript/Vite+. src/main.rs dispatches GUI, CLI, and MCP modes in one binary.
src/interfaces/exposes CLI and stdio MCP. CLI widget reads and writes usewidgets::store::Storeoffline; MCP forwards requests to the resident GUI over local IPC, starting it on demand.src/transport/owns that IPC, widget resource serving, and CSP. IPC uses Unix sockets or Windows named pipes.src/widgets/owns persisted widget content, metadata, and board frames.src/runtime/owns native windows, placement, screenshots, and host APIs; its watcher reconciles stored changes with running windows.ui/src/main/implements the management window.ui/src/widget/is the trusted shell around an opaque-origin sandboxed iframe containing widget content. Keep widget content outside the shell's Tauri privileges.src/agents/manages external Agent integrations;src/community/handles the widget catalog and package installation;src/update/handles app self-update.
- Rust owns shared frontend types. Edit their Rust definitions, register new
exports in
src/bin/typegen.rs, then runpnpm typegen; never editui/src/types/rust.tsby hand. CI verifies it withpnpm typegen --check. - A Tauri command needs registration in
src/runtime/commands.rs, a window-role entry insrc/runtime/command_names.rs, and a matching capability grant. Native authorization and Tauri ACL are separate gates, tested independently.permissions/autogenerated/is build output; do not edit it.
- Fail fast with explicit errors; do not add fallback logic unless requested. Let errors propagate without handling them inside the business layer.
- Preserve existing changes. Do not revert staged files or check out, commit from, clean, or delete another session's worktree or logs.
- Before changing code, follow docs/coding.md.
- For local checks, pull requests, merging, and the version model, follow docs/development.md.
- Before changing the updater, follow docs/self-update.md.
- Before release work, follow docs/releasing.md.
- When writing a commit message, follow .github/COMMIT_MESSAGE_INSTRUCTIONS.md.