diff --git a/modules/prompt/functions/promptpwd b/modules/prompt/functions/promptpwd index b8fcc0c..af30e7c 100644 --- a/modules/prompt/functions/promptpwd +++ b/modules/prompt/functions/promptpwd @@ -9,6 +9,8 @@ local ret_directory if [[ "$current_pwd" == (#m)[/~] ]]; then ret_directory="$MATCH" unset MATCH +elif zstyle -t ':prezto:module:prompt' long-pwd; then + ret_directory=${current_pwd} else ret_directory="${${${${(@j:/:M)${(@s:/:)current_pwd}##.#?}:h}%/}//\%/%%}/${${current_pwd:t}//\%/%%}" fi diff --git a/runcoms/zpreztorc b/runcoms/zpreztorc index 8b2af26..3741a1c 100644 --- a/runcoms/zpreztorc +++ b/runcoms/zpreztorc @@ -97,6 +97,9 @@ zstyle ':prezto:module:editor' key-bindings 'emacs' # Auto set to 'off' on dumb terminals. zstyle ':prezto:module:prompt' theme 'sorin' +# Display pwd in long format for themes that use promptpwd function +# zstyle ':prezto:module:prompt' long-pwd 'yes' + # # Ruby #