mirror of
https://github.com/zdharma-continuum/zinit.git
synced 2026-09-10 07:36:38 -04:00
zplugin,autoload: Support LOADED_PLUGINS defined by Zsh plugin standard
This commit is contained in:
parent
780b024935
commit
5d5e376cda
|
|
@ -1055,6 +1055,7 @@ ZPLGM[EXTENDED_GLOB]=""
|
|||
else
|
||||
(( quiet )) || print "Unregistering plugin $uspl2col"
|
||||
-zplg-unregister-plugin "$user" "$plugin"
|
||||
LOADED_PLUGINS[${LOADED_PLUGINS[(i)$user/$plugin]}]=() # Support Zsh plugin standard
|
||||
-zplg-clear-report-for "$user" "$plugin"
|
||||
(( quiet )) || print "Plugin's report saved to \$LASTREPORT"
|
||||
fi
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
#
|
||||
|
||||
typeset -gaH ZPLG_REGISTERED_PLUGINS ZPLG_TASKS ZPLG_RUN
|
||||
typeset -ga LOADED_PLUGINS
|
||||
ZPLG_TASKS=( "<no-data>" )
|
||||
# Snippets loaded, url -> file name
|
||||
typeset -gAH ZPLGM ZPLG_REGISTERED_STATES ZPLG_SNIPPETS ZPLG_REPORTS ZPLG_ICE ZPLG_SICE
|
||||
|
|
@ -938,6 +939,9 @@ builtin setopt noaliases
|
|||
fi
|
||||
fi
|
||||
|
||||
# Support Zsh plugin standard
|
||||
LOADED_PLUGINS+=( "$user/$plugin" )
|
||||
|
||||
(( ${+ZPLG_ICE[atinit]} )) && { local __oldcd="$PWD"; builtin cd -q "${${${(M)user:#%}:+$plugin}:-${ZPLGM[PLUGINS_DIR]}/${user}---${plugin}}" && eval "${ZPLG_ICE[atinit]}"; builtin cd -q "$__oldcd"; }
|
||||
|
||||
-zplg-load-plugin "$user" "$plugin" "$mode"
|
||||
|
|
|
|||
Loading…
Reference in a new issue