1
0
Fork 0
mirror of https://github.com/romkatv/powerlevel10k.git synced 2024-12-18 05:40:07 +00:00

adds back trunaction protection for /* in truncate_to_unique

This commit is contained in:
Syphdias 2019-05-26 23:38:54 +02:00
parent bead0ec05e
commit 837bb94aa1
No known key found for this signature in database
GPG key ID: 6F62E6FB3E67F92D

View file

@ -836,6 +836,7 @@ prompt_dir() {
;;
truncate_to_unique)
local -i i=2 n=1 d=0
[[ $p == /* ]] && (( ++i ))
delim=${POWERLEVEL9K_SHORTEN_DELIMITER-'*'}
shortenlen=${POWERLEVEL9K_SHORTEN_DIR_LENGTH:-1}
d=${POWERLEVEL9K_SHORTEN_DELIMITER_LENGTH:-$#POWERLEVEL9K_SHORTEN_DELIMITER}