From a4f6b757be11d796990b89fc6f86be67162b57ef Mon Sep 17 00:00:00 2001 From: Eric Nielsen Date: Tue, 26 Sep 2017 15:23:30 +0200 Subject: [PATCH] [template] Add zcompile of git-info to zlogin and declare `zim_mods` as a local variable. Also minor formatting changes. Closes #215 --- templates/zlogin | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/zlogin b/templates/zlogin index c004ffc..bac8e6c 100644 --- a/templates/zlogin +++ b/templates/zlogin @@ -12,12 +12,12 @@ # does not exist, or the base file is newer, we need to compile. # These jobs are asynchronous, and will not impact the interactive shell zcompare() { - if [[ -s ${1} && ( ! -s ${1}.zwc || ${1} -nt ${1}.zwc) ]]; then + if [[ -s ${1} && ( ! -s ${1}.zwc || ${1} -nt ${1}.zwc ) ]]; then zcompile ${1} fi } - zim_mods=${ZIM_HOME}/modules + local zim_mods=${ZIM_HOME}/modules setopt EXTENDED_GLOB # zcompile the completion cache; siginificant speedup. @@ -30,6 +30,7 @@ # zcompile some light module init scripts zcompare ${zim_mods}/git/init.zsh + zcompare ${zim_mods}/git-info/init.zsh zcompare ${zim_mods}/utility/init.zsh zcompare ${zim_mods}/pacman/init.zsh zcompare ${zim_mods}/spectrum/init.zsh @@ -54,6 +55,5 @@ # zsh-histery-substring-search zcompare ${zim_mods}/history-substring-search/external/zsh-history-substring-search.zsh - ) &!