Merge pull request #4291 from seregaxvm/master

add zsh -h autocomplete option
This commit is contained in:
Mikhail Korobov 2020-02-07 23:42:10 +05:00 committed by GitHub
commit 7e341e0f6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -1,11 +1,12 @@
#compdef scrapy #compdef scrapy
_scrapy() { _scrapy() {
local context state state_descr line local context state state_descr line
local ret=1
typeset -A opt_args typeset -A opt_args
_arguments \ _arguments \
"(- 1 *)--help[Help]" \ "(- 1 *)"{-h,--help}"[Help]" \
"1: :->command" \ "1: :->command" \
"*:: :->args" "*:: :->args" && ret=0
case $state in case $state in
command) command)
@ -134,6 +135,8 @@ _scrapy() {
esac esac
;; ;;
esac esac
return ret
} }
_scrapy_cmds() { _scrapy_cmds() {