KetraTerm
API · v0.2.2All versions

activeShellCommandLineRevision

Revision of the active shell command line, tracked only while collected.

Collectors share one tracker running on the session worker dispatcher, independently of render publication. Tracking buffers are allocated on subscription and released when the last collector leaves. Merely reading StateFlow.value does not start tracking.

The value is -1 before an active OSC 133 command line is observed and resets to -1 when tracking stops. A new subscription samples the latest published live frame without waiting for more terminal output.

Nonnegative values identify render generations where command text, cursor anchor, or snapshot availability changed. Treat them as opaque revisions; intermediate changes may be conflated. Consumers should debounce this signal and call activeShellCommandLine when they need a command snapshot. Session closure cancels tracking; collectors own their collection lifetime.