From 3057e8fc07374e9c580790a023cb85998ca91fc8 Mon Sep 17 00:00:00 2001 From: Dominik Ritter Date: Fri, 1 Mar 2019 23:31:21 +0100 Subject: [PATCH] Backport @wrboyce fix for truncating dir with package name from #1158 --- powerlevel9k.zsh-theme | 2 ++ 1 file changed, 2 insertions(+) diff --git a/powerlevel9k.zsh-theme b/powerlevel9k.zsh-theme index 427e9b00..4939cb35 100755 --- a/powerlevel9k.zsh-theme +++ b/powerlevel9k.zsh-theme @@ -905,6 +905,8 @@ prompt_dir() { package_path=${$(pwd)%%/.git*} fi + [[ ${(L)POWERLEVEL9K_DIR_PATH_ABSOLUTE} != "true" ]] && package_path=${package_path/$HOME/"~"} + # Replace the shortest possible match of the marked folder from # the current path. Remove the amount of characters up to the # folder marker from the left. Count only the visible characters