dfe35e1bfa
to autoloads the functions and sources the scripts, instead of executing zimfw during startup, and having it always figuring out what do to on the fly. This takes out the worry about zimfw interfering with the startup time, and allows room to add more features to it. So, zstyle was replaced by a custom zmodule function to define the modules, with the extra ability of allowing users to set custom fpath paths, autoloaded functions and sourced scripts per module.
19 lines
624 B
Plaintext
19 lines
624 B
Plaintext
_zimfw_clean_compiled() {
|
|
local zopt_find zopt_rm zdir
|
|
if (( ! _zquiet )); then
|
|
zopt_find='-print'
|
|
zopt_rm='-v'
|
|
fi
|
|
for zdir in ${fpath}; do
|
|
[[ ${zdir} == (.|..) || ${zdir} == (.|..)/* ]] && continue
|
|
if [[ -w ${zdir:h} ]]; then
|
|
command rm -f ${zopt_rm} ${zdir}.zwc{,.old} || return 1
|
|
fi
|
|
done
|
|
command find ${ZIM_HOME} \( -name '*.zwc' -o -name '*.zwc.old' \) -delete ${zopt_find} || return 1
|
|
command rm -f ${zopt_rm} <%= home %>/.zshrc.zwc{,.old} || return 1
|
|
if (( ! _zquiet )); then
|
|
print -P '%F{green}✓%f Done with clean-compiled. Run %Bzimfw compile%b to re-compile.'
|
|
fi
|
|
}
|