# harian12/mytermin architecture

> Architecture diagram of the GitHub repository harian12/mytermin, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/harian12/mytermin
- Repository: https://github.com/harian12/mytermin

## Overview

MyTermin is a Windows developer-workspace desktop app combining isolated project workstations, multi-terminal sessions, a Monaco editor, file/Git tools, and task and AI-assisted workflows. The principal flow is: a developer opens a project, works in its file explorer and editor, runs commands in a workstation terminal, and manages changes or searches across the project. The graph also includes documented supporting capabilities such as configuration, notifications, and port management. Some subsystem links rely on the README because their source was not sampled; uncertain wiring is omitted.

Main entry points: [`src-tauri/src/main.rs`](https://github.com/harian12/mytermin/blob/main/src-tauri/src/main.rs) (Tauri commands), [`app/app.vue`](https://github.com/harian12/mytermin/blob/main/app/app.vue) (Application shell), [`app/composables/useProjectExplorer.ts`](https://github.com/harian12/mytermin/blob/main/app/composables/useProjectExplorer.ts) (Project explorer and Git), [`app/components/TerminalPane.vue`](https://github.com/harian12/mytermin/blob/main/app/components/TerminalPane.vue) (Terminal panes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workspace["Workspace and UI"]
  node_app["Application shell<br/>[app.vue]"]
  node_workspace_store["Workstation sessions"]
  node_layout["Workspace layout<br/>[LayoutGrid.vue]"]
  node_sidebar["Workstation explorer UI"]
end

subgraph group_terminal["Terminal and tasks"]
  node_terminal_ui["Terminal panes<br/>[TerminalPane.vue]"]
  node_pty_client["PTY client<br/>[useTauriPty.ts]"]
  node_tasks["Task runner UI<br/>[TaskPanel.vue]"]
  node_ai_runner["AI CLI runner<br/>[AiPanelModal.vue]"]
end

subgraph group_project["Project and code"]
  node_editor_ui["Monaco editor<br/>[CodeEditorPane.vue]"]
  node_editor_store["Editor sessions<br/>[useEditorStore.ts]"]
  node_explorer["Project explorer and Git"]
end

subgraph group_support["Search and settings"]
  node_search_ui["Project search"]
  node_settings["Settings and notifications"]
  node_project_config["Project config and env"]
  node_port_ui["Port manager"]
  node_port_manager["Port operations<br/>[usePortManager.ts]"]
end

subgraph group_desktop["Desktop runtime"]
  node_pty_runtime["PTY runtime<br/>[pty.rs]"]
  node_backend["Tauri commands<br/>[main.rs]"]
end

node_developer(("Developer"))
node_project_files[("Project files")]
node_session_storage[("Local session storage")]
node_shell["System shells and tools"]
node_browser["Default browser"]

node_developer -->|"uses"| node_app
node_app -->|"manages sessions"| node_workspace_store
node_app -->|"displays workspace"| node_layout
node_app -->|"displays navigation"| node_sidebar
node_app -->|"hosts editor"| node_editor_ui
node_workspace_store -->|"persists sessions"| node_session_storage
node_layout -->|"arranges panes"| node_terminal_ui
node_terminal_ui -->|"controls PTYs"| node_pty_client
node_pty_client -->|"invokes commands"| node_backend
node_backend -->|"manages PTYs"| node_pty_runtime
node_pty_runtime -->|"runs processes"| node_shell
node_tasks -->|"sends task output"| node_terminal_ui
node_ai_runner -->|"launches CLI"| node_terminal_ui
node_editor_ui -->|"edits files"| node_editor_store
node_editor_store -->|"reads and writes"| node_backend
node_backend -->|"accesses files"| node_project_files
node_sidebar -->|"browses project"| node_explorer
node_explorer -->|"invokes file and Git commands"| node_backend
node_explorer -->|"scans project"| node_project_files
node_search_ui -->|"searches project"| node_explorer
node_app -->|"loads project settings"| node_project_config
node_settings -->|"stores preferences"| node_session_storage
node_port_ui -->|"requests port actions"| node_port_manager
node_port_manager -->|"invokes port commands"| node_backend
node_backend -->|"inspects or kills processes"| node_shell
node_port_manager -->|"opens port URL"| node_browser

click node_app "https://github.com/harian12/mytermin/blob/main/app/app.vue"
click node_workspace_store "https://github.com/harian12/mytermin/blob/main/app/composables/useWorkspaceStore.ts"
click node_layout "https://github.com/harian12/mytermin/blob/main/app/components/LayoutGrid.vue"
click node_sidebar "https://github.com/harian12/mytermin/blob/main/app/components/WorkstationSidebar.vue"
click node_terminal_ui "https://github.com/harian12/mytermin/blob/main/app/components/TerminalPane.vue"
click node_pty_client "https://github.com/harian12/mytermin/blob/main/app/composables/useTauriPty.ts"
click node_pty_runtime "https://github.com/harian12/mytermin/blob/main/src-tauri/src/pty.rs"
click node_tasks "https://github.com/harian12/mytermin/blob/main/app/components/TaskPanel.vue"
click node_ai_runner "https://github.com/harian12/mytermin/blob/main/app/components/AiPanelModal.vue"
click node_editor_ui "https://github.com/harian12/mytermin/blob/main/app/components/CodeEditorPane.vue"
click node_editor_store "https://github.com/harian12/mytermin/blob/main/app/composables/useEditorStore.ts"
click node_explorer "https://github.com/harian12/mytermin/blob/main/app/composables/useProjectExplorer.ts"
click node_search_ui "https://github.com/harian12/mytermin/blob/main/app/components/GlobalSearchModal.vue"
click node_settings "https://github.com/harian12/mytermin/blob/main/app/composables/useSettingsStore.ts"
click node_project_config "https://github.com/harian12/mytermin/blob/main/app/composables/useProjectConfig.ts"
click node_port_ui "https://github.com/harian12/mytermin/blob/main/app/components/PortManagerModal.vue"
click node_port_manager "https://github.com/harian12/mytermin/blob/main/app/composables/usePortManager.ts"
click node_backend "https://github.com/harian12/mytermin/blob/main/src-tauri/src/main.rs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_workspace_store,node_layout,node_sidebar,node_browser toneBlue
class node_terminal_ui,node_pty_client,node_tasks,node_ai_runner,node_project_files,node_session_storage toneAmber
class node_editor_ui,node_editor_store,node_explorer toneMint
class node_search_ui,node_settings,node_project_config,node_port_ui,node_port_manager toneRose
class node_pty_runtime,node_backend,node_developer,node_shell toneIndigo
```

## Components

### Workspace and UI

- [Application shell](https://github.com/harian12/mytermin/blob/main/app/app.vue): `app/app.vue`
- [Workstation sessions](https://github.com/harian12/mytermin/blob/main/app/composables/useWorkspaceStore.ts): `app/composables/useWorkspaceStore.ts`
- [Workspace layout](https://github.com/harian12/mytermin/blob/main/app/components/LayoutGrid.vue): `app/components/LayoutGrid.vue`
- [Workstation explorer UI](https://github.com/harian12/mytermin/blob/main/app/components/WorkstationSidebar.vue): `app/components/WorkstationSidebar.vue`

### Terminal and tasks

- [Terminal panes](https://github.com/harian12/mytermin/blob/main/app/components/TerminalPane.vue): `app/components/TerminalPane.vue`
- [PTY client](https://github.com/harian12/mytermin/blob/main/app/composables/useTauriPty.ts): `app/composables/useTauriPty.ts`
- [Task runner UI](https://github.com/harian12/mytermin/blob/main/app/components/TaskPanel.vue): `app/components/TaskPanel.vue`
- [AI CLI runner](https://github.com/harian12/mytermin/blob/main/app/components/AiPanelModal.vue): `app/components/AiPanelModal.vue`

### Project and code

- [Monaco editor](https://github.com/harian12/mytermin/blob/main/app/components/CodeEditorPane.vue): `app/components/CodeEditorPane.vue`
- [Editor sessions](https://github.com/harian12/mytermin/blob/main/app/composables/useEditorStore.ts): `app/composables/useEditorStore.ts`
- [Project explorer and Git](https://github.com/harian12/mytermin/blob/main/app/composables/useProjectExplorer.ts): `app/composables/useProjectExplorer.ts`

### Search and settings

- [Project search](https://github.com/harian12/mytermin/blob/main/app/components/GlobalSearchModal.vue): `app/components/GlobalSearchModal.vue`
- [Settings and notifications](https://github.com/harian12/mytermin/blob/main/app/composables/useSettingsStore.ts): `app/composables/useSettingsStore.ts`
- [Project config and env](https://github.com/harian12/mytermin/blob/main/app/composables/useProjectConfig.ts): `app/composables/useProjectConfig.ts`
- [Port manager](https://github.com/harian12/mytermin/blob/main/app/components/PortManagerModal.vue): `app/components/PortManagerModal.vue`
- [Port operations](https://github.com/harian12/mytermin/blob/main/app/composables/usePortManager.ts): `app/composables/usePortManager.ts`

### Desktop runtime

- [PTY runtime](https://github.com/harian12/mytermin/blob/main/src-tauri/src/pty.rs): `src-tauri/src/pty.rs`
- [Tauri commands](https://github.com/harian12/mytermin/blob/main/src-tauri/src/main.rs): `src-tauri/src/main.rs`

### Other components

- **Developer**
- **Project files**
- **Local session storage**
- **System shells and tools**
- **Default browser**

## Connections

- Developer → Application shell: uses
- Application shell → Workstation sessions: manages sessions
- Application shell → Workspace layout: displays workspace
- Application shell → Workstation explorer UI: displays navigation
- Application shell → Monaco editor: hosts editor
- Workstation sessions → Local session storage: persists sessions
- Workspace layout → Terminal panes: arranges panes
- Terminal panes → PTY client: controls PTYs
- PTY client → Tauri commands: invokes commands
- Tauri commands → PTY runtime: manages PTYs
- PTY runtime → System shells and tools: runs processes
- Task runner UI → Terminal panes: sends task output
- AI CLI runner → Terminal panes: launches CLI
- Monaco editor → Editor sessions: edits files
- Editor sessions → Tauri commands: reads and writes
- Tauri commands → Project files: accesses files
- Workstation explorer UI → Project explorer and Git: browses project
- Project explorer and Git → Tauri commands: invokes file and Git commands
- Project explorer and Git → Project files: scans project
- Project search → Project explorer and Git: searches project
- Application shell → Project config and env: loads project settings
- Settings and notifications → Local session storage: stores preferences
- Port manager → Port operations: requests port actions
- Port operations → Tauri commands: invokes port commands
- Tauri commands → System shells and tools: inspects or kills processes
- Port operations → Default browser: opens port URL
