From a57b97285c3308fbdcc167ab3da9ae1dd78767b6 Mon Sep 17 00:00:00 2001 From: Ogulcan Celik Date: Mon, 23 Mar 2026 00:36:52 +0300 Subject: initial release terminal workspace manager for AI coding agents. single rust binary, runs inside your existing terminal. workspaces, tiled panes, intelligent agent state detection. https://herdr.dev --- src/events.rs | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 src/events.rs (limited to 'src/events.rs') diff --git a/src/events.rs b/src/events.rs new file mode 100644 index 00000000..e86850cb --- /dev/null +++ b/src/events.rs @@ -0,0 +1,26 @@ +//! Internal app events delivered via channel. +//! +//! Background tasks (PTY child watchers, future hook listeners, etc.) send +//! events to the main loop through this channel. No polling needed. + +use crate::detect::{Agent, AgentState}; +use crate::layout::PaneId; + +/// An event from a background task to the main loop. +#[derive(Debug)] +pub enum AppEvent { + /// A pane's child process exited. + PaneDied { + pane_id: PaneId, + }, + /// Agent state changed in a pane (detected by the PTY reader). + StateChanged { + pane_id: PaneId, + agent: Option, + state: AgentState, + }, + /// A new version was downloaded and installed. Restart to use it. + UpdateReady { + version: String, + }, +} -- cgit v1.2.3