From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21406 invoked by alias); 2 Feb 2016 11:22:05 -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: 21222 Received: (qmail 27977 invoked from network); 2 Feb 2016 11:22:03 -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,FREEMAIL_FROM, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=HLVYOnboVSwM4NbiSeobkzbqWkS3OLsatXoblZ1sHgU=; b=E7EorRyNhTAMGim0w7Cq6oEkjM5gvgZ/FyKwam8X0yssbWsaBEXY+Nta3iCzH4ov1N mIsh9W1cgr+UrVRm6npiHecF5XkbXGkhZU0Yjrmo8FPsoxSV3VCXHZn08v/z9/nFN5PO 6iJDvAzH/zc7RK3sQMskX46NKQZqW6G1Iw1MlepPHuzcl3ju254JV8mYeDRKPPNbEO/B yeWxNuviFKqCBrzcS/EBc7lI7oRKeMxsQg7rzMVK4yIzYON2K1KuRuHVdHtFgijBlp+Y 3MGOab95gXbeM9oTKQhwgbCAoY8CoFzdUv1+anGe/ZXunOOCzxWIuRVZ9KEfVrV40gWH rbwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=HLVYOnboVSwM4NbiSeobkzbqWkS3OLsatXoblZ1sHgU=; b=mjq6RtQi1Sb5DE9yIlyrJLoCCpfkh+v8vTBk1NZS2wOEXEcL0ewNrcZe9gNoYdJS6n twwQ17diObomCj+hi46squBCZliKi8cR8T0Oam43JG5VRIa/Qk8AVmfa2c0uAHhVChgh bu+w6XMkObX+wfETz7x1X/tNYzZg07YAT4GzMwnumgCrdt7rg0JQ9rlAMeJm3fTSN20m cd7hZOUjUyBJr6sMmUj3Ey4Nyo38R6cIfPXd24SRV2PZ3Eh9spZtoAcXabHCipAq0HPE FaOtSuclrv9yySd6ctgNk8ed6ppMPCedSqy8zAp87CVWYSDnMqJe5lRIszWD0jq4emEX mx6w== X-Gm-Message-State: AG10YOQ4dVAO40LIcyIbbpc7CspFa4alW8XbUNbehZ+KpdyhcDrfIVZAg3GCr9S3gT0iWLuDjdd/DvSRW2xutQ== X-Received: by 10.25.83.209 with SMTP id h200mr11058359lfb.129.1454412120680; Tue, 02 Feb 2016 03:22:00 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <160201133104.ZM30504@torch.brasslantern.com> References: <160129144546.ZM24675@torch.brasslantern.com> <160131093929.ZM11508@torch.brasslantern.com> <160201065310.ZM29704@torch.brasslantern.com> <160201133104.ZM30504@torch.brasslantern.com> From: Sebastian Gniazdowski Date: Tue, 2 Feb 2016 12:21:41 +0100 Message-ID: Subject: Re: Color in completions To: Bart Schaefer Cc: Zsh Users Content-Type: text/plain; charset=UTF-8 On 1 February 2016 at 22:31, Bart Schaefer wrote: > On Feb 1, 5:25pm, Sebastian Gniazdowski wrote: > } Subject: Re: Color in completions > } > } On 1 February 2016 at 15:53, Bart Schaefer wrote: > } > On Feb 1, 8:49am, Sebastian Gniazdowski wrote: > } > } > } > } tags in context :completion::complete:zplugin:: > } > } argument-1 (_arguments _zplugin) > } > } commands (_describe _zplugin) > > Hmm, I get (after editing _zplugin to add -C): > > burner% zplg > tags in context :completion::complete:zplg:: > argument-1 (_arguments _zplugin) > tags in context :completion::complete:zplg:argument-1: > commands (_zplugin) The "zplg" is weird. Again to compare what I have: % zplg tags in context :completion::complete:zplugin:: argument-1 (_arguments _zplugin) commands (_describe _zplugin) When I add -C to _arguments (btw, when to use -C?): % zpl tags in context :completion::complete:zplugin:: argument-1 (_arguments _zplugin) tags in context :completion::complete:zplugin:argument-1: commands (_describe _zplugin) > burner% zplg unload > tags in context :completion::complete:zplg:: > argument-rest (_arguments _zplugin) > tags in context :completion::complete:zplg:argument-rest: > plugins (_zplugin) With -C: # zplg unload tags in context :completion::complete:zplugin:: argument-rest (_arguments _zplugin) tags in context :completion::complete:zplugin:argument-rest: plugins (_zplugin) > What's different about the _zplugin you're using from the one in github? No difference. BTW. I above pasted what zsh-5.0.8 and zsh-5.2 gives (the same outputs) > I'd forgotten that argument-N and argument-rest can appear in both the > ARGUMENT position and TAG position in the standard completion context. > > Also if you look through the _complete_debug output, the context used > is really :completion::complete:zplg:argument-rest:argument-rest so > you need something in the ARGUMENT. I wonder why _complete_help gets > that wrong, but that's why both :argument-rest:* and :*:argument-rest > work. What zstyle would you do to handle zpl, zplg aliases? I could provide multiple Zstyles so that no user will be left without colors. > } > zstyle ':completion:*:zplugin:*' list-colors ... > } > } I already had (#mark): > } zstyle ':completion:*:zplugin:*:argument-rest' list-colors > } '=(#b)(*)/(*)==1;35=1;33' > } > } Comparing that to your proposition: > } zstyle ':completion:*:zplugin:*' list-colors ... > } zstyle ':completion:*:zplugin:*:argument-rest' list-colors ... > } > } it seems that the zstyle #mark is correct, it just matches more - also > } the "argument-rest", which is expected, because plugin names may > } appear after a command > > Your #mark style is more specific than my suggestion. That means it > matches neither the argument-1 tag nor the command and plugins tags. I wish I could understand all this better. Best regards, Sebastian Gniazdowski