|
|
@ -202,11 +202,10 @@ fi
|
|
|
|
# * $1: The segment to be tested.
|
|
|
|
# * $1: The segment to be tested.
|
|
|
|
segment_in_use() {
|
|
|
|
segment_in_use() {
|
|
|
|
local key=$1
|
|
|
|
local key=$1
|
|
|
|
if [[ -n "${POWERLEVEL9K_LEFT_PROMPT_ELEMENTS[(r)$key]}" ]] || [[ -n "${POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS[(r)$key]}" ]]; then
|
|
|
|
[[ -n "${POWERLEVEL9K_LEFT_PROMPT_ELEMENTS[(r)${key}]}" ||
|
|
|
|
return 0
|
|
|
|
-n "${POWERLEVEL9K_LEFT_PROMPT_ELEMENTS[(r)${key}_joined]}" ||
|
|
|
|
else
|
|
|
|
-n "${POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS[(r)${key}]}" ||
|
|
|
|
return 1
|
|
|
|
-n "${POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS[(r)${key}_joined]}" ]]
|
|
|
|
fi
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
# Print a deprecation warning if an old segment is in use.
|
|
|
|
# Print a deprecation warning if an old segment is in use.
|
|
|
|