From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25756 invoked by alias); 20 Nov 2015 03:18:59 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 37163 Received: (qmail 1679 invoked from network); 20 Nov 2015 03:18:56 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.0 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= daniel.shahaf.name; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=Sd4v/HvHbp7GkdIeaoV+0WKIssg=; b=fg73jL SfOwfrNKZlmC0gcEKh4eU5YTpsVRGiEKyZvGQ0GWXlEBw74aOa2378xkxeL7s7mg hbDJjaBvpc35lDwVF3sajaGfO+EAp2NDt1W8Pr+k49bc16d2l4KJWn8kvT3EoE01 sSI4n69rZ222bWYvUzpnXXgJSYmcaRh5XiWM8= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=smtpout; bh=Sd4v/HvHbp7GkdIeaoV+0WKIssg=; b=ecXz/ rBVY6WHWnkmwRlkt26iFerMdhhlXrm9kZxZ1DAbu5auLnTB0aVIYxC5clxbN1nSF tEn4gYp9lOjLOJLc56HE10CphpZg70ncG+RQZvLOGoU1NbYauGOHxNeQPdUBcWma kucLxo5fGlF+nXGyeL4OecvJTM3ybLfhK4fl74= X-Sasl-enc: QXmXt+XnSS+fiSVakMVYHCNq9T5oBpRA/vuUK1aBZRYy 1447989531 Date: Fri, 20 Nov 2015 03:18:46 +0000 From: Daniel Shahaf To: zsh-workers@zsh.org Subject: Re: [PATCH] Remove curl completion Message-ID: <20151120031658.GA3955@tarsus.local2> References: <20151118231618.GI2070@tarsus.local2> <151118162052.ZM5511@torch.brasslantern.com> <20151119114106.GB20857@cventin.lip.ens-lyon.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20151119114106.GB20857@cventin.lip.ens-lyon.fr> User-Agent: Mutt/1.5.21 (2010-09-15) Vincent Lefevre wrote on Thu, Nov 19, 2015 at 12:41:06 +0100: > On 2015-11-18 16:20:52 -0800, Bart Schaefer wrote: > > On Nov 18, 11:16pm, Daniel Shahaf wrote: > > } Upstream now ships a completion that is a superset of this one. > > > > I wish there were some way to conditionalize this. I dislike the > > assumption that bleeding-edge curl and bleeding-edge zsh will always > > be installed together. If I upgrade zsh but not curl, suddenly my > > curl completion disappears entirely. > > Shouldn't the part concerning curl in > $prefix/share/zsh/functions/Completion/Unix/_urls > be moved to its own .../Completion/Unix/_curl, and curl install > its completion in $prefix/share/zsh/vendor-completions so that > it has the precedence? +1. Will this suffice to implement Vincent's idea? diff --git a/Completion/Unix/Command/_curl b/Completion/Unix/Command/_curl new file mode 100644 index 0000000..72e2e5b --- /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 6f23803..e81eaac 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: #