Files
ide/architecture.md
T

22 lines
1.4 KiB
Markdown

# Architecture
Git.Zone IDE is split into a local Electron shell and a remote Theia workspace server.
## Local Electron Shell
The Electron app is intentionally small. It owns SSH host selection, remote bootstrap execution, local SSH tunnel lifecycle, and workspace windows. It does not implement remote filesystem, terminal, Git, or OpenCode behavior itself.
## Remote Theia Server
The remote server is a Theia browser application installed under `~/.git.zone/ide-server/<version>`. It runs on the SSH host, bound to `127.0.0.1`, and is accessed only through an SSH local port forward.
## OpenCode Integration
The Electron shell starts a local `opencode serve` runtime for each opened project. The native shell owns OpenCode sessions, messages, permissions, and chat UI. Git.Zone writes OpenCode tool overrides into that local runtime so shell, file, search, and patch operations are forwarded over SSH and execute in the selected remote workspace.
Theia does not host OpenCode chat or OpenCode sessions. Any future Theia-facing tool should be an intellisense/context provider for editor and language-server state, not another OpenCode transport.
## Execution Boundary
Files, terminal commands, Git, language servers, builds, tests, Git.Zone commands, and bridged OpenCode code tools all run on the remote SSH host. The local machine displays UI, runs the local OpenCode provider process, and maintains SSH transport.