summaryrefslogtreecommitdiff
path: root/internal/p10k.zsh
diff options
context:
space:
mode:
Diffstat (limited to 'internal/p10k.zsh')
-rw-r--r--internal/p10k.zsh7
1 files changed, 5 insertions, 2 deletions
diff --git a/internal/p10k.zsh b/internal/p10k.zsh
index 206ebcfe..21059708 100644
--- a/internal/p10k.zsh
+++ b/internal/p10k.zsh
@@ -4840,7 +4840,10 @@ function _p9k_init_cacheable() {
)
local -i i=0
- local -a left_segments=(${(@0)_p9k_line_segments_left[@]})
+ # This simpler construct doesn't work on zsh-5.1 with multi-line prompt:
+ #
+ # ${(@0)_p9k_line_segments_left[@]}
+ local -a left_segments=(${(@0)${(pj:\0:)_p9k_line_segments_left}})
_p9k_left_join=(1)
for ((i = 2; i <= $#left_segments; ++i)); do
local elem=$left_segments[i]
@@ -4851,7 +4854,7 @@ function _p9k_init_cacheable() {
fi
done
- local -a right_segments=(${(@0)_p9k_line_segments_right[@]})
+ local -a right_segments=(${(@0)${(pj:\0:)_p9k_line_segments_right}})
_p9k_right_join=(1)
for ((i = 2; i <= $#right_segments; ++i)); do
local elem=$right_segments[i]