aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkatherine <shmibs@shmibbles.me>2017-09-09 23:12:58 -0700
committerkatherine <shmibs@shmibbles.me>2017-09-09 23:12:58 -0700
commitf0a556fc35600e7e3b426a2557e51e76d9877539 (patch)
tree06692d0574da370cec0c759f3bb7c965cb3f7665
parent0381a50f10bd3649a61d6e246224eb8023b30d66 (diff)
downloaddotfiles-f0a556fc35600e7e3b426a2557e51e76d9877539.tar.gz
source local zsh-syntax-highlighting on freebsd
-rw-r--r--.zshrc13
1 files changed, 8 insertions, 5 deletions
diff --git a/.zshrc b/.zshrc
index 848413f..600e2f0 100644
--- a/.zshrc
+++ b/.zshrc
@@ -77,11 +77,14 @@ fi
################# HIGHLIGHTING ################
-if [[ -f '/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh' ]]; then
- source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
-else
- source ~/.zsh/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
-fi
+local HIGHLIGHT_DIR='~/.zsh/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh'
+[[ -f '/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh' ]] && \
+ HIGHLIGHT_DIR='/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh'
+[[ -f '/usr/local/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh' ]] && \
+ HIGHLIGHT_DIR='/usr/local/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh'
+
+source $HIGHLIGHT_DIR
+
ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern)
#ZSH_HIGHLIGHT_STYLES[alias]="fg=yellow"