How arisros/tmux-agent-deck works
tmux-agent-deck is a Claude Code agent-state dashboard implemented as a tmux plugin. Claude hooks send events to deck; the hook adapter maps them to state-machine events, the deck persists session state and publishes pane options, and tmux formats and views expose that state. Users reach agents through the popup, sidebar, tabs, and borders. Separate documented capabilities include screen-based reconciliation, usage and plan reporting, sounds, and installation checks. Relationships for unsampled modules are included only where the README or source index supports them.
Main entry points: hookcmd.go Hook commands · viewcmd.go View commands · main.go Command dispatch · tmux.go tmux operations
Components 19
Commands and setup
- Command dispatch
cmd/deck/main.go - Hook commands
cmd/deck/hookcmd.go - Settings installer
cmd/deck/installcmd.go - Settings editing
internal/install/install.go - tmux setup
cmd/deck/tmuxinit.go
Agent state
- Hook mapping
internal/hook/hook.go - State machine
internal/machine/machine.go - State adapter
internal/deck/deck.go - Session records
internal/store/store.go - Event recorder
internal/record/record.go - tmux operations
internal/tmux/tmux.go
Views and display
- View commands
cmd/deck/viewcmd.go - Agent rows
internal/ui/rows.go - Popup and sidebar
internal/ui/views.go
Usage and diagnostics
- Usage tracking
internal/usage/usage.go - Installation checks
cmd/deck/doctor.go
Other components
- tmux user
- Claude Code
- tmux server
Connections 32
- tmux user → Command dispatch: invokes commands
cmd/deck/main.go - Command dispatch → Hook commands: dispatches hooks
cmd/deck/main.go - Command dispatch → View commands: dispatches views
cmd/deck/main.go - Command dispatch → Settings installer: dispatches setup
cmd/deck/main.go - Command dispatch → tmux setup: dispatches setup
cmd/deck/main.go - Claude Code → Hook commands: sends hook events
- Hook commands → Hook mapping: decodes events
cmd/deck/hookcmd.go - Hook mapping → State machine: maps events
internal/hook/hook.go - Hook commands → State adapter: applies events
cmd/deck/hookcmd.go - State adapter → State machine: updates state
internal/deck/deck.go - State adapter → Session records: loads and saves
internal/deck/deck.go - State adapter → tmux operations: publishes options
internal/deck/deck.go - tmux operations → tmux server: runs commands
README.md - Claude Code → Event recorder: optional event trace
- Hook commands → Event recorder: records events
cmd/deck/hookcmd.go - tmux user → View commands: opens popup or sidebar
README.md - View commands → tmux operations: queries panes
cmd/deck/viewcmd.go - View commands → Agent rows: builds agent rows
cmd/deck/viewcmd.go - View commands → Popup and sidebar: renders lists
cmd/deck/viewcmd.go - Agent rows → State machine: uses state labels
internal/ui/rows.go - Agent rows → tmux operations: uses pane data
internal/ui/rows.go - Agent rows → Usage tracking: shows usage
internal/ui/rows.go - tmux setup → tmux server: sets keys and formats
README.md - Claude Code → Usage tracking: sends status data
README.md - Hook commands → Usage tracking: records status data
cmd/deck/hookcmd.go - Usage tracking → View commands: supplies plan usage
README.md - tmux user → Settings installer: requests installation
README.md - Settings installer → Settings editing: edits Claude settings
cmd/deck/installcmd.go - tmux user → Installation checks: checks installation
- Installation checks → Settings editing: checks configured hooks
cmd/deck/doctor.go - Installation checks → tmux operations: checks tmux setup
cmd/deck/doctor.go - Installation checks → Session records: checks state directory
cmd/deck/doctor.go