mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-01-31 15:25:15 +08:00
tmux-prompt test to wait a bit to allow the first prompt to draw
The tmux-prompt test would sometimes fail because the first call was: isolated-tmux capture-pane -p this would run a capture-pane which would race with starting fish itself; occasionally the pane would be empty since fish has not yet drawn a prompt. Add a loop to give fish time to draw the prompt.
This commit is contained in:
parent
9070ed8039
commit
5eb5aaf9da
|
@ -8,6 +8,15 @@ set -g isolated_tmux_fish_extra_args -C '
|
|||
end
|
||||
'
|
||||
|
||||
# Start it up and loop a bit, until we get an initial prompt.
|
||||
isolated-tmux
|
||||
for i in seq 10
|
||||
if string match -q '*prompt*' (isolated-tmux capture-pane -p)
|
||||
break
|
||||
end
|
||||
sleep .5
|
||||
end
|
||||
|
||||
isolated-tmux capture-pane -p
|
||||
# CHECK: prompt 0> <>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user