Workspace Command Center UI
Relevant source files
The following files were used as context for generating this wiki page:
The Workspace Command Center UI serves as the primary control plane for managing parallel coding agent workflows within Linux Archductor. It provides a centralized interface where developers can manage isolated Git worktree workspaces, launch agent sessions (such as Codex or Claude Code), review code changes, and handle the lifecycle of GitHub Pull Requests (PRs). The interface is built using GTK4 and libadwaita, optimized for Linux desktop environments.
The UI is structured to facilitate a continuous loop: creating a workspace for a specific task, engaging with agents through a chat-first selection model, reviewing diffs and checks, and finally merging or archiving work. It bridges the gap between local file systems, PTY-backed harnesses for agents, and remote GitHub repository states.
Sources: README.md:1-25, progress.md:10-30
Interface Architecture
The Workspace Command Center utilizes a complex layout managed by a horizontal Paned split. The architecture ensures that high-frequency tasks like chat interactions and file editing are prioritized in the center, while supplementary information like file trees and runtime controls are accessible in the side panels.
Layout Structure
The layout is divided into three primary regions:
- Sidebar: Handles workspace navigation, search, and grouping by repository.
- Center Panel: Contains the session header, a dynamic tab bar for agent chats and open files, and the primary content stack (Chat/Terminal/Editor).
- Right Panel: Houses the workspace summary, file tree/changes switcher, and the "Run Console" for executing scripts and terminal commands.
The split position is calculated using a weighted ratio (default 5:3) with minimum constraints to ensure readability on various screen sizes.
Sources: crates/gtk-app/src/workspace_command_center.rs:136-180, crates/gtk-app/src/workspace_command_center.rs:198-212
Center Panel and Chat Management
The center panel is the workspace's functional core, managing the lifecycle of agent "threads." It supports multiple concurrent chat sessions, typically limited to 10 visible tabs.
Chat Thread Lifecycle
Threads represent persisted conversations with specific agents (e.g., Codex, Claude). The UI allows users to create new threads, reopen closed ones through a context menu, and switch between threads using the dynamic tab bar.
| Component | Description |
|---|---|
| Tab Bar | Displays active chat threads and open file tabs with close buttons and context menus. |
| Add Button (+) | Creates a new chat thread using the first available ready provider (Codex/Claude). |
| Reopen Button | Visible only when "closed" threads exist; allows restoring previous sessions. |
| External Selection | Syncs thread selection between the UI and the underlying archcar session manager. |
Sources: crates/gtk-app/src/workspace_command_center.rs:305-360, crates/gtk-app/src/workspace_command_center.rs:480-520
Integrated File Editor
When a file is selected from the file tree or changes list, it opens as a new tab in the center panel. This editor supports three modes:
- Edit: A monospace
TextViewfor manual modifications. - Diff: Shows the specific git diff for that file within the workspace context.
- Preview: A word-wrapped view, primarily for Markdown files.
Sources: crates/gtk-app/src/workspace_command_center.rs:555-610
Right Panel and Runtime Controls
The right panel provides high-level observability and direct command execution capabilities.
Run Console
The Run Console is a specialized widget that manages repository scripts and interactive terminals. It tracks the state of setup and run scripts defined in .archductor/settings.toml.
The Console allows users to:
- Stage Prompts: "Queue" setup/run scripts into an agent session if the scripts are missing or need updates.
- Interactive PTYs: Launch and interact with multiple terminal instances per workspace.
- Session Persistence: Terminals are backed by
archcarsessions, ensuring they persist across UI refreshes.
Sources: crates/gtk-app/src/workspace_command_center.rs:220-300, crates/gtk-app/src/workspace_command_center.rs:815-880
Pull Request and Checks Workflow
A critical feature of the Command Center is its tight integration with GitHub via the gh CLI. The "Checks" tab (and the PR status panel) transforms raw GitHub metadata into actionable agent prompts.
Pull Request States
The UI normalizes PR states into a simplified status model:
| State | Logic / Requirements | UI Feedback |
|---|---|---|
| Merged | State is "merged" | Green badge; options to Continue or Archive. |
| Failed | Any failing check or deployment | Red badge; "Fix checks" prompt available. |
| Pending | In-progress checks | Yellow badge; "PR summary" available. |
| Ready | Approved + Passed Checks + No Blockers | Green badge; "Merge" action enabled. |
| Open | No specific attention needed | Muted badge; basic refresh/summary. |
Sources: crates/gtk-app/src/workspace_command_center.rs:1145-1210, crates/gtk-app/src/workspace_command_center.rs:1360-1420
Merge Blockers
The UI prevents merging if local blockers exist, even if GitHub checks pass. These include:
- Open todos in the workspace.
- Unresolved local review comments.
- Sibling workspace conflicts (parallel work on the same files).
Sources: crates/gtk-app/src/workspace_command_center.rs:1580-1600, crates/gtk-app/src/workspace_command_center.rs:1410-1425
Workspace Lifecycle Management
Workspace lifecycle actions are managed through both the sidebar context menus and a dedicated lifecycle panel.
Action Types
- Rename: Changes the local workspace display name.
- Duplicate: Creates a new worktree/branch based on the current workspace state.
- Archive: Safely stops processes and moves the workspace to an "archived" state (preserving history).
- Discard/Delete: Destructive actions that remove the worktree and/or the local branch.
- Spotlight: A specialized testing mode that syncs workspace patches against a clean repository root.
Sources: crates/gtk-app/src/sidebar.rs:375-450, crates/gtk-app/src/workspace_command_center.rs:945-1030
Summary of Secondary Panels
The workspace stack includes several auxiliary panels for deep inspection:
- Changes Tab: Combines
git status,git log, and a unified diff viewer with syntax highlighting for additions and deletions. - Todos Tab: Manages a local SQLite-backed list of tasks specific to the workspace.
- Timeline Tab: Shows a persisted event history (creation, branch actions, session starts).
- Checkpoints Tab: Allows manual creation and restoration of workspace state snapshots.
- Conflicts Panel: Detects when parallel workspaces have modified the same files and allows "Copy from sibling" workflows.
Sources: crates/gtk-app/src/workspace_command_center.rs:710-800, crates/gtk-app/src/workspace_command_center.rs:1480-1550, crates/gtk-app/src/workspace_command_center.rs:1725-1800
The Workspace Command Center UI is designed to minimize context switching, providing all necessary tools for agentic software development within a single, cohesive Linux desktop application. Its structure emphasizes visibility of changes and readiness of the codebase for merging.