diff options
Diffstat (limited to 'Completion')
-rw-r--r-- | Completion/Base/Utility/_regex_words | 8 | ||||
-rw-r--r-- | Completion/Unix/Command/_curl | 7 | ||||
-rw-r--r-- | Completion/Unix/Type/_urls | 2 |
3 files changed, 15 insertions, 2 deletions
diff --git a/Completion/Base/Utility/_regex_words b/Completion/Base/Utility/_regex_words index 77ba197a4..62c2491bb 100644 --- a/Completion/Base/Utility/_regex_words +++ b/Completion/Base/Utility/_regex_words @@ -20,7 +20,13 @@ local tag=$1 local desc=$2 shift 2 -reply=(\() +if (( $# )); then + reply=(\() +else + # ### Is this likely to happen in callers? Should we warn? + reply=() + return +fi integer i local -a wds diff --git a/Completion/Unix/Command/_curl b/Completion/Unix/Command/_curl new file mode 100644 index 000000000..72e2e5b53 --- /dev/null +++ b/Completion/Unix/Command/_curl @@ -0,0 +1,7 @@ +#compdef curl + +# As of 7.43.0, curl upstream provides its own _curl definition. This +# definition is provided as a fallback, and should be installed later +# in $fpath than the curl-provided definition of _curl. + +_urls "$@" diff --git a/Completion/Unix/Type/_urls b/Completion/Unix/Type/_urls index 6f23803ed..e81eaac05 100644 --- a/Completion/Unix/Type/_urls +++ b/Completion/Unix/Type/_urls @@ -1,4 +1,4 @@ -#compdef curl -value-,WWW_HOME,-default- -P -value-,(ftp|http(|s))_proxy,-default- +#compdef -value-,WWW_HOME,-default- -P -value-,(ftp|http(|s))_proxy,-default- # Configuration styles used: # |