Documentation
¶
Index ¶
- Constants
- Variables
- func EnsureMonitorDir(dir string) error
- func MatchesPrimarySource(bs BackendStatus, source string) bool
- type AgentDiscoveredMsg
- type AgentLaunchedMsg
- type BackendAvailableMsg
- type BackendStatus
- type ConfigSavedMsg
- type DirBrowserItem
- type DirBrowserMsg
- type DiscoveryTickMsg
- type FocusedMsg
- type GitInfo
- type IntegrationToggledMsg
- type Model
- func (m Model) Cleanup()
- func (m *Model) EnableDebugLog(path string, unsafe bool) error
- func (m Model) Init() tea.Cmd
- func (m *Model) SetConfig(cfg *config.Config, path string)
- func (m *Model) SetPTYClient(pty terminal.Backend)
- func (m *Model) SetStatusInfo(info StatusInfo)
- func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd)
- func (m Model) View() string
- type MonitorStartedMsg
- type PromptSentMsg
- type QuickResponseArmExpiredMsg
- type ScreenReadMsg
- type SessionsRefreshedMsg
- type SpinnerTickMsg
- type StatusInfo
- type StatusMsg
- type StatusTickMsg
- type StatusUpdatedMsg
- type UpgradeAvailableMsg
- type VisibleRefreshMsg
Constants ¶
const Logo = ` _ _
__ _| |_ _ __(_) __ _
/ _` + "`" + ` | __| '__| |/ _` + "`" + ` |
| (_| | |_| | | | (_| |
\__,_|\__|_| |_|\__,_|`
Logo is the standard figlet-font ASCII art for Atria, shared across the version flag, empty state, and setup wizard.
Variables ¶
var Version = "dev"
Version is set by main.go from build-time ldflags.
Functions ¶
func EnsureMonitorDir ¶
func MatchesPrimarySource ¶ added in v0.3.0
func MatchesPrimarySource(bs BackendStatus, source string) bool
MatchesPrimarySource reports whether a backend status entry corresponds to the given composite primary source name. Handles the iterm2→iterm mapping.
Types ¶
type AgentDiscoveredMsg ¶
type AgentDiscoveredMsg struct {
SessionID string
AgentType model.AgentType
Source string // backend source ("pty", "iterm", "tmux", etc.)
Dir string // resolved working directory, empty if not found
DebugSkip string // optional discovery skip reason for debug logging
}
AgentDiscoveredMsg is sent when an untracked agent has been identified and its CWD resolved.
type AgentLaunchedMsg ¶
type AgentLaunchedMsg struct {
ProjectDir string
SessionID string
AgentType model.AgentType
Source string // backend source ("pty", "tmux", etc.), empty = use primary
Err error
}
AgentLaunchedMsg is sent after launching an agent in a new session.
type BackendAvailableMsg ¶
type BackendAvailableMsg struct {
Err error
}
BackendAvailableMsg indicates whether the backend is usable.
type BackendStatus ¶
type BackendStatus struct {
Name string // "pty", "iterm2", "tmux"
Enabled bool // in integrations list
Active bool // enabled + probe OK + environment matches
Launch bool // is the launch target
Reason string // why unavailable or not active
}
BackendStatus describes the state of a backend for the settings screen.
type ConfigSavedMsg ¶
type ConfigSavedMsg struct {
Err error
Rollback func(m *Model) // reverts optimistic mutations on save failure
}
ConfigSavedMsg is sent after persisting config to disk. If Err is non-nil and Rollback is set, the handler calls Rollback to revert in-memory mutations that were applied optimistically.
type DirBrowserItem ¶
DirBrowserItem represents a directory in the add-project browser.
type DirBrowserMsg ¶
type DirBrowserMsg struct {
Dirs []DirBrowserItem
CurrentDir string
}
DirBrowserMsg contains directories for the browser view.
type DiscoveryTickMsg ¶ added in v0.4.2
type DiscoveryTickMsg struct{}
DiscoveryTickMsg triggers periodic session discovery refresh.
type GitInfo ¶
type GitInfo struct {
IsWorktree bool
ParentRepo string // basename of main repo
Branch string // worktree branch name
}
GitInfo holds git worktree metadata for a directory.
type IntegrationToggledMsg ¶
type IntegrationToggledMsg struct {
Name string
Status BackendStatus
Err error
RemappedIDs map[string]string // old session ID → new session ID (e.g. PTY demotion)
NewPrimary string // source of the new launch target (set on both enable and disable)
}
IntegrationToggledMsg is sent after toggling an integration on or off.
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
func NewModelWithConfig ¶
func (*Model) EnableDebugLog ¶
EnableDebugLog sets up debug logging to the given file path.
func (*Model) SetPTYClient ¶
SetPTYClient sets the PTY client reference for integration toggling.
func (*Model) SetStatusInfo ¶
func (m *Model) SetStatusInfo(info StatusInfo)
SetStatusInfo sets the backend status info for the settings screen.
type MonitorStartedMsg ¶
type MonitorStartedMsg struct {
SessionID string
ProjectDir string
PID int
LogPath string
Err error
}
MonitorStartedMsg is sent after starting a monitor process.
type PromptSentMsg ¶
PromptSentMsg is sent after sending a prompt to an agent.
type QuickResponseArmExpiredMsg ¶ added in v0.4.0
type QuickResponseArmExpiredMsg struct {
SessionID string
}
QuickResponseArmExpiredMsg clears the transient armed quick-response state.
type ScreenReadMsg ¶
ScreenReadMsg contains screen content read from a session.
type SessionsRefreshedMsg ¶
SessionsRefreshedMsg is sent when the session list has been refreshed.
type StatusInfo ¶
type StatusInfo struct {
Backends []BackendStatus
ConfigPath string
}
StatusInfo holds backend status information built during startup.
type StatusMsg ¶
type StatusMsg struct {
Text string
}
StatusMsg is a transient message shown in the status bar.
type StatusTickMsg ¶ added in v0.4.2
type StatusTickMsg struct{}
StatusTickMsg triggers background status polling.
type StatusUpdatedMsg ¶
type StatusUpdatedMsg struct {
SessionID string
ProjectDir string
Status model.AgentStatus
Activity string
Attention string
}
StatusUpdatedMsg is sent when agent status has been checked.
type UpgradeAvailableMsg ¶ added in v0.3.0
UpgradeAvailableMsg is sent when a newer version is available on GitHub.
type VisibleRefreshMsg ¶ added in v0.4.2
type VisibleRefreshMsg struct {
SessionID string
}
VisibleRefreshMsg triggers a fast refresh for the currently visible session.