... | ... |
@@ -10,14 +10,23 @@ for config_file ($ZSH/lib/*.zsh) source $config_file |
10 | 10 |
# Load all of your custom configurations from custom/ |
11 | 11 |
for config_file ($ZSH/custom/*.zsh) source $config_file |
12 | 12 |
|
13 |
-# Load all of the plugins that were defined in ~/.zshrc |
|
13 |
+# Add all defined plugins to fpath |
|
14 | 14 |
plugin=${plugin:=()} |
15 |
-for plugin ($plugins) source $ZSH/plugins/$plugin/$plugin.plugin.zsh |
|
15 |
+for plugin ($plugins) fpath=($ZSH/plugins/$plugin $fpath) |
|
16 | 16 |
|
17 | 17 |
# Load and run compinit |
18 | 18 |
autoload -U compinit |
19 | 19 |
compinit -i |
20 | 20 |
|
21 |
+# Load all of the plugins that were defined in ~/.zshrc |
|
22 |
+for plugin ($plugins) |
|
23 |
+do |
|
24 |
+ if [ -f $ZSH/plugins/$plugin/$plugin.plugin.zsh ] |
|
25 |
+ then |
|
26 |
+ source $ZSH/plugins/$plugin/$plugin.plugin.zsh |
|
27 |
+ fi |
|
28 |
+done |
|
29 |
+ |
|
21 | 30 |
# Load the theme |
22 | 31 |
source "$ZSH/themes/$ZSH_THEME.zsh-theme" |
23 | 32 |
|