a more simple and universal way (for zsh projects) to find highlight dir path

This commit is contained in:
Evan Pitstick 2013-10-09 12:02:34 -04:00
parent 0fcc2629d2
commit dffbab0c92

View file

@ -198,7 +198,7 @@ _zsh_highlight_bind_widgets || {
}
# Resolve highlighters directory location.
_zsh_highlight_load_highlighters "${ZSH_HIGHLIGHT_HIGHLIGHTERS_DIR:-$(dirname "$(readlink -f $0)")/highlighters}" || {
_zsh_highlight_load_highlighters "${ZSH_HIGHLIGHT_HIGHLIGHTERS_DIR:-${${0:A}:h}/highlighters}" || {
echo 'zsh-syntax-highlighting: failed loading highlighters, exiting.' >&2
return 1
}