diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 1999-11-17 09:57:16 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 1999-11-17 09:57:16 +0000 |
commit | 881d24cd48b4c659760961991e0f029900c54a8e (patch) | |
tree | f6d30fc7892055adae9e3dd4cce19baee7b750fc /Completion/Base/_describe | |
parent | 3a84a91e2bb455546a0e01cfe6b6b68ca70b1efb (diff) | |
download | zsh-881d24cd48b4c659760961991e0f029900c54a8e.tar.gz zsh-881d24cd48b4c659760961991e0f029900c54a8e.tar.xz zsh-881d24cd48b4c659760961991e0f029900c54a8e.zip |
manual/8654
Diffstat (limited to 'Completion/Base/_describe')
-rw-r--r-- | Completion/Base/_describe | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/Completion/Base/_describe b/Completion/Base/_describe index 181ccbfcb..f1fbbafc6 100644 --- a/Completion/Base/_describe +++ b/Completion/Base/_describe @@ -2,21 +2,15 @@ # This can be used to add options or values with descriptions as matches. -local _cmd _opt _expl _tmps _tmpd _tmpmd _tmpms _ret=1 _showd _nm _hide _args +local _opt _expl _tmps _tmpd _tmpmd _tmpms _ret=1 _showd _nm _hide _args local _type=values -_cmd="$words[1]" +# Get the option. -# Get the options. - -while getopts 'oc:' _opt; do - if [[ "$_opt" = o ]]; then - _type=options - else - _cmd="$OPTARG" - fi -done -shift OPTIND-1 +if [[ "$1" = -o ]]; then + _type=options + shift +fi # Do the tests. `showd' is set if the descriptions should be shown. |