Expand description
tear-core — runtime logic for the tear multiplexer.
Houses the session/window/pane state machine, PTY ownership
(portable-pty), the layout engine, and the InProcess
implementation of tear_types::MultiplexerControl.
§Why this matters for the mado integration
mado currently owns its own pane.rs/tab.rs with private
state machines. At M5 those modules rebase onto
tear-core::InProcess — both apps then share one source of
truth for pane semantics. This crate’s InProcess impl is the
gravitational center the eventual rebase lands on.
No daemon — those live in tear-daemon. Daemon-side composition
wraps InProcess rather than reimplementing.
Re-exports§
pub use blocks::BlockExtractor;pub use inproc::InProcess;pub use reap::AllPanesExited;pub use pane_grid::PaneGrid;pub use recording::PaneEvent;pub use recording::PaneRecording;
Modules§
- blocks
- Pane-as-block — OSC 133 prompt-mark-driven block extractor.
- inproc
InProcess— the in-memorytear_types::MultiplexerControlimplementation backed byparking_lot::RwLock<Registry>+BTreeMap<PaneId, PtyHandle>.- pane_
grid - Per-pane terminal cell grid driven by a
vteparser. - pty
- PTY ownership — one
PtyHandleper running pane. - reap
- The typed admission ticket for daemon-initiated session removal.
- recording
- Per-pane recording — captures every PTY byte with a relative
timestamp, exposes a ring-buffered snapshot, and exports as
asciinema v2 .cast (JSON-lines) so any external player handles
playback. Daemon-native: no
asciinema recwrapper needed. - registry
- In-memory session/window/pane registry — the typed state machine
every
crate::InProcessop composes against.
Structs§
- Block
- Re-export the wire shape so callers don’t have to choose between tear-core and tear-types — they’re the same type.
- Cell
- One cell in a snapshotted pane. Carries the rendered character
- Pane
Snapshot - Serializable snapshot of one pane’s visible grid + cursor. Sent over the tear-daemon ↔ tear-client wire so consumers can render without holding a reference into the live parser state.