1
0
Fork 0
mirror of https://github.com/romkatv/powerlevel10k.git synced 2024-11-12 08:10:07 +00:00

Fallback mechanism is now more robust. If does not matter if the user specified a file or a directory in POWERLEVEL9K_INSTALLATION_PATH.

This commit is contained in:
Dominik Ritter 2015-11-28 01:33:33 +01:00
parent 972e24ad41
commit 46575182c7

View file

@ -32,6 +32,10 @@ if [[ $(whence -w prompt_powerlevel9k_setup) =~ "function" ]]; then
print -P "%F{red}We could not locate the installation path of powerlevel9k.%f" print -P "%F{red}We could not locate the installation path of powerlevel9k.%f"
print -P "Please specify by setting %F{blue}POWERLEVEL9K_INSTALLATION_PATH%f (full path incl. file name) at the very beginning of your ~/.zshrc" print -P "Please specify by setting %F{blue}POWERLEVEL9K_INSTALLATION_PATH%f (full path incl. file name) at the very beginning of your ~/.zshrc"
return 1 return 1
elif [[ -f "$POWERLEVEL9K_INSTALLATION_PATH" ]]; then
0="$POWERLEVEL9K_INSTALLATION_PATH"
elif [[ -d "$POWERLEVEL9K_INSTALLATION_PATH" ]]; then
0="${POWERLEVEL9K_INSTALLATION_PATH}/powerlevel9k.zsh-theme"
fi fi
0=$POWERLEVEL9K_INSTALLATION_PATH 0=$POWERLEVEL9K_INSTALLATION_PATH