From 00772b72a7a79b6f35b1b805c305a4b6fc285659 Mon Sep 17 00:00:00 2001 From: Sven Wischnowsky Date: Tue, 23 May 2000 13:18:36 +0000 Subject: add -E option to zparseopts (11530) --- Doc/Zsh/mod_zutil.yo | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Doc') diff --git a/Doc/Zsh/mod_zutil.yo b/Doc/Zsh/mod_zutil.yo index a0e53697d..7aef70a3a 100644 --- a/Doc/Zsh/mod_zutil.yo +++ b/Doc/Zsh/mod_zutil.yo @@ -131,7 +131,7 @@ item(tt(zregexparse))( This implements the internals of the `tt(_regex_arguments)'. ) findex(zparseopts) -item(tt(zparseopts) [ tt(-D) ] [ tt(-a) var(array) ] [ tt(-A) var(assoc) ] var(specs))( +item(tt(zparseopts) [ tt(-D) ] [ tt(-E) ] [ tt(-a) var(array) ] [ tt(-A) var(assoc) ] var(specs))( This builtin simplifies the parsing of options in positional parameters, i.e. the set of arguments given by tt($*). Each var(spec) describes one option and should be of the form @@ -167,6 +167,9 @@ positional parameters, up to but not including any not described by the var(specs). This means that any options processed by tt(zparseopts) are removed from the positional parameters. +The tt(-E) option allows to extract the options described by the +var(specs) from the positional parameters, ignoring all other strings. + For example, example(set -- -a -bx -c y -cz baz -cend -- cgit 1.4.1