diff options
Diffstat (limited to 'zshrc')
-rw-r--r-- | zshrc | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -3,7 +3,12 @@ # config files and plugins located relative to this file # directory this file is in -CFG_DIR=$(dirname $(readlink -f ~/.zshrc)) +local CFG_DIR +if [ -z "$ZSH_CFG_DIR" ]; then + CFG_DIR=$(dirname $(readlink -f "${(%):-%N}")) +else + CFG_DIR="$ZSH_CFG_DIR" +fi for plugin in $CFG_DIR/plugins/*(N); do # add *.zsh if no *.plugin.zsh found |