From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26297 invoked by alias); 23 Oct 2013 13:47:11 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 18055 Received: (qmail 14430 invoked from network); 23 Oct 2013 13:47:04 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI, SPF_HELO_PASS autolearn=ham version=3.3.2 X-AuditID: cbfec7f5-b7ef66d00000795a-57-5267d355e92d Date: Wed, 23 Oct 2013 14:47:00 +0100 From: Peter Stephenson To: "zsh-users@zsh.org" Subject: Re: Glob problem Message-id: <20131023144700.43a7849a@pwslap01u.europe.root.pri> In-reply-to: <91F9ED9F-B198-403B-9FE1-FF40DE960C1C@gmail.com> References: <65DB21EB-86B6-479C-8F25-35B9B832CFD5@gmail.com> <5266BFF6.4050004@oracle.com> <20131023.051117.47078782.ghostrevery@gmail.com> <91F9ED9F-B198-403B-9FE1-FF40DE960C1C@gmail.com> Organization: Samsung Cambridge Solution Centre X-Mailer: Claws Mail 3.7.9 (GTK+ 2.22.0; i386-redhat-linux-gnu) MIME-version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFuplluLIzCtJLcpLzFFi42I5/e/4Fd3Qy+lBBmdO6ljsOLmS0YHRY9XB D0wBjFFcNimpOZllqUX6dglcGcsWLmQsaBCsWLTgMVMD43feLkZODgkBE4muz3uYIWwxiQv3 1rN1MXJxCAksZZR4cuUJjMMk0fDsIBtIFYuAqsTWCb9ZQWw2AUOJqZtmM4LYIgLaEh/7joNN EhaQlDg99z1QDQcHr4C9xJwWR5Awp4CtxPM/C1ggZn5mlHhz+TtYPb+AvsTVv5+YIK6wl5h5 5QzYTF4BQYkfk++xgNjMAloSm7c1sULY8hKb17xlnsAoMAtJ2SwkZbOQlC1gZF7FKJpamlxQ nJSea6RXnJhbXJqXrpecn7uJERKEX3cwLj1mdYhRgINRiYfXoj0tSIg1say4MvcQowQHs5II r9SF9CAh3pTEyqrUovz4otKc1OJDjEwcnFINjLovtxvqBB5kauJY6bc0Pq9g3dzX2zYcUlTk 6irb6nlcxn7bh7PsR05UTLT50fZkZ3DhuzYZt5gJWo6+u9ab65Zzr0tK0YiPXza5Zc9qYem5 f+O2O/125tugYPqRdXfxjp2zb3/7UVfeX+r+Q8B80hY370mdR96eSnt/5qdp/KbGCOHqrhcS q5VYijMSDbWYi4oTAWlQxD4gAgAA On Wed, 23 Oct 2013 08:27:22 -0400 Brent Briggs wrote: > This did the job. I still have one question. I can't find any > documentation for the "--" option. What does it do exactly? It's documented for shell invocation in the zsh manual page, but I don't see anything about option handling for builtins. There probably should be something. Some of the regulars can tell me if the following looks right. diff --git a/Doc/Zsh/builtins.yo b/Doc/Zsh/builtins.yo index 1d9fe68..e9fc7bf 100644 --- a/Doc/Zsh/builtins.yo +++ b/Doc/Zsh/builtins.yo @@ -28,6 +28,33 @@ See ifzman(the section `Zle Builtins' in zmanref(zshzle))\ ifnzman(noderef(Zle Builtins)). )\ )\ + +Some shell builtin commands take options as given in invidiual entries. +Typically options are single letters preceded by a hyphen (tt(-)). +Options that take an argument accept it either immediately following the +option letter or after white space, for example `tt(print -C3 *)' or +`tt(print -C 3 *)' are equivalent. Arguments to options are not the +same as arguments to the command; the documentation indicates which is +which. Options that do not take an argument may be combined in a single +word, for example `tt(print -ca *)' and `tt(print -c -a *)' are +equivalent. + +Some shell builtin commands also take options that begin with `tt(+)' +instead of `tt(-)'. These commands are indicated in the list below. + +Options must appear in a group before any non-option arguments; +once the first non-option argument has been found, option processing is +terminated. + +All builtin commands other than precommand modifiers, even those that +have no options, can be given the argument `tt(--)' to terminate option +processing. This indicates that the following words are non-option +arguments, but is otherwise ignored. This is useful in cases where +arguments to the command may begin with `tt(-)'. For historical +reasons, most builtin commands also recognize a single `tt(-)' in a +separate word for this purpose; note that this is less standard and +use of `tt(--) is recommended. + startitem() prefix(-) findex(.) pws