1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-30 07:10:58 +02:00
zsh/Completion/Base/_brace_parameter
1999-11-16 13:08:17 +00:00

29 lines
644 B
Text

#compdef -brace-parameter-
_tags parameters && _parameters -e
# Without the `-e' option, we would use the following (see the file
# Core/_parameters for more enlightenment).
# local lp ls n q
# if [[ "$SUFFIX" = *\}* ]]; then
# ISUFFIX="${SUFFIX#*\}}$ISUFFIX"
# SUFFIX="${SUFFIX%%\}*}"
# suf=()
# elif [[ "$LBUFFER" = *\$\{[^}]#\$\{[^}]#$PREFIX ||
# "$compstate[insert]" = *menu* ]]; then
# suf=(-b '')
# else
# suf=(-b ' ')
# fi
# lp="$LBUFFER[1,-${#PREFIX}-1]"
# ls="$RBUFFER[${#SUFFIX}+1,-1]"
# n=${(M)#ls##\"#}
# q=${(M)lp%%\"#}
# [[ n -gt 0 ]] && suf=''
# _parameters "$suf[@]" -Qs "${q[1,-n-1]}" -r '-:?#%+=[/}'