mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-11-15 18:59:33 +01:00
fix(terminal): remote and Docker tabs keep the byte tail on a switch (#588 merge-time fix)
A remote (ssh) or Docker session's local pane hosts a nested tmux client in the alternate screen, so it always reports paneHistoryLines 0 while its byte tail carries the real scrolled-off output. The new full=1 switch therefore replaced their scrollback with the visible frame on every revisit. Those sessions now keep the tail; the pinned test string and the invariants note say so. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
7ba1e51c51
commit
1855d9423b
3 files changed
+6
-3
No files matched your search
@@ -9394,7 +9394,10 @@ class CodemanApp {
|
||||
// response re-reports the count, so a pane that starts keeping history
|
||||
// (claude switched to its inline view) goes back to the tail on the next
|
||||
// switch.
|
||||
const paneKeepsNoHistory = this._paneHistoryLines?.get(sessionId) === 0;
|
||||
// A remote (ssh) or Docker session's local pane hosts a nested tmux client in the
|
||||
// alternate screen, so it reports 0 while its byte tail is real scrollback.
|
||||
const paneKeepsNoHistory =
|
||||
!session?.remote && !session?.docker && this._paneHistoryLines?.get(sessionId) === 0;
|
||||
const useFullHistory =
|
||||
session?.mode !== 'shell' && (paneKeepsNoHistory || !this._fullHistoryLoaded.has(sessionId));
|
||||
if (useFullHistory) this._fullHistoryLoaded.add(sessionId);
|
||||
|
||||
Reference in new issue
Block a user