mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-15 14:22:43 +00:00
An idle terminal tab (no command ever typed) grew one extra copy of the shell's boot prompt on every close/reopen: persistSnapshot re-serialized a buffer that was just the replayed old prompt plus the fresh shell's new prompt, and cleanReviveSnapshot's blank-line trim can't strip prompts on shells like default PowerShell that print no separator line. Track real user input (keystrokes/paste, drag-and-drop paths, injected commands) and, when a session had none, skip re-serializing. If the buffer we loaded carried no real scrollback (empty or only a repeated prompt), clear it so the next launch shows a single fresh prompt and any existing accumulation heals; otherwise leave the prior snapshot untouched so real history from an earlier active session survives an idle reopen. Salvages #61584 (activity tracking) and #61577 (clearing content-free idle buffers) into one path: it also heals already-polluted buffers, counts drag-and-drop and injected input as activity, and never discards genuine short command history (only empty/all-identical buffers are cleared). Co-authored-by: alelpoan <alelpoan@proton.me> Co-authored-by: liuhao1024 <sunsky.lau@gmail.com> |
||
|---|---|---|
| .. | ||
| bootstrap-installer | ||
| desktop | ||
| shared | ||