mirror of
https://github.com/zdharma-continuum/zinit.git
synced 2026-09-10 07:36:38 -04:00
Add %PLUGINS support.
This commit is contained in:
parent
888b3a8c1c
commit
c822aca8be
|
|
@ -885,8 +885,8 @@ builtin setopt noaliases
|
|||
# Is it absolute path in zinit format?
|
||||
if [[ $1 = %* ]]; then
|
||||
local -A map
|
||||
map=( "" "" HOME $HOME SNIPPETS $ZINIT[SNIPPETS_DIR] )
|
||||
reply=( % ${${1/(#b)(#s)%(HOME|SNIPPETS|)/$map[$match[1]]}} )
|
||||
map=( HOME $HOME SNIPPETS $ZINIT[SNIPPETS_DIR] PLUGINS $ZINIT[PLUGINS_DIR] )
|
||||
reply=( % ${${1/(#b)(#s)%(${(~j:|:)${(@k)map}}|)/$map[$match[1]]}} )
|
||||
reply[2]=${~reply[2]}
|
||||
return 0
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in a new issue