Distinguish builtin read history session ID from private mode

Fixes #12662
This commit is contained in:
Johannes Altmanninger
2026-04-29 00:28:31 +08:00
parent e5f57b1daf
commit 281399561b
11 changed files with 96 additions and 41 deletions

View File

@@ -1,4 +1,4 @@
#RUN: %fish %s
#RUN: fish=%fish %fish %s
#REQUIRES: command -v tmux
#REQUIRES: test -z "$CI"
@@ -25,3 +25,20 @@ isolated-tmux capture-pane -p
# CHECK: prompt 4> : fooba
# CHECK: prompt 5> : fooba
# CHECK: foobar foobaz
isolated-tmux send-keys C-u C-l \
'read' Enter read-input Enter
tmux-sleep
isolated-tmux send-keys \
'set fish_history' Enter \
'true some command; read' Enter
tmux-sleep
isolated-tmux send-keys C-p
tmux-sleep
isolated-tmux capture-pane -p
# CHECK: prompt 5> read
# CHECK: read> read-input
# CHECK: read-input⏎
# CHECK: prompt 6> set fish_history
# CHECK: prompt 6> true some command; read
# CHECK: read> read-input