Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Complete certain external commands separately by path?
- X-seq: zsh-users 22898
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: dana <dana@xxxxxxx>
- Subject: Re: Complete certain external commands separately by path?
- Date: Thu, 14 Sep 2017 06:48:57 +0000
- Cc: zsh-users@xxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= daniel.shahaf.name; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=Fa7s+zBvWMNoWhqBEvoDH6zscO3L0OokXlOG7oTy2sg=; b=DSAomPwi AOvvxFayq/D7fPYW31tM62MmSw0Q5FXCswqc8OzadUi7Rbev8KCuVgLLoL2tABCu sEcoY+5o/p/YIXo5PQD4bvXkAoDowalHtjyGVDZz+W3TxkIfVHd0vhPbovYAmbI9 /uWOZHFuBNWV6nJg3Z2Z4ZWNm81yjR/qTwIr0cIPifxhaniXdkcaGGFcvunbygWo i5bJND4BMqqZFFWM9W6JvACD5fUP9VGRAA6DjKWqDqr+8xx51WWNLWEV9H+gBMQI 7yIiSsFMxEsj1Rw5rTrod/LEAZl3qPAJunOH/Apf5HPBKAZcxAAWcHy/GKheNqFt hQlQjLWGtTULwA==
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=Fa7s+zBvWMNoWhqBEvoDH6zscO3L0OokXlOG7oTy2sg=; b=ZNsC63Yz BV6DKAOL6wlSVc8t/V2FcNrBfr1GLygI2ogwZ0d34UBkwXZu7RTagLqqhh19eKm8 42w6OeXiDHzCF2ZAVlIw90cU3V5xlRoLoFWf8HRnjXRU9IdO+A7k54ASoePKw5V8 p8cCgRfet+ZSSY/jmxgM7N8Uh5CgaBasnr1u2eJmnc3DXcZEUVkXOvPxb+E2oi9k KrBuVcu8asjmzsRvfzuXpir2WUSxewaRgeINp874W03BYS9G5l+C9Ie4s7bz1AkB uyUpT//DQcimLNBpnfiUYyMGZtt/SlgZN1wR2ofjFhbimkj0PgvRzZ+0ds/CvSi5 ehQCuBtpqyTOrQ==
- In-reply-to: <CA+_8RBBL7wYb2aHGg5fe6k4f0w8i8zEVhqa7cVmNiKU6BPnkvQ@mail.gmail.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <CA+_8RBDYxA3zZT47FPncrO7rqXmb8i+S=B52tLPxA-gD34qsoQ@mail.gmail.com> <CA+_8RBBL7wYb2aHGg5fe6k4f0w8i8zEVhqa7cVmNiKU6BPnkvQ@mail.gmail.com>
dana wrote on Tue, Sep 12, 2017 at 02:32:50 -0500:
> # Put a `commands-bin2` tag ahead of the regular `commands` one
> zstyle ':completion:*:-command-:*' tag-order 'commands:-bin2:favoured\ external\ command commands *'
> zstyle ':completion:*:-command-:*:commands-bin2' ignored-patterns "^(${(kj<|>)commands[(R)/bin2/*]})"
> zstyle ':completion:*:-command-:*:commands' ignored-patterns "(${(kj<|>)commands[(R)/bin2/*]})"
>
> If you can think of anything wrong with this method please let me know.
> Otherwise it seems to work so far!
It only affects command names that are completed at command position,
i.e., it affects this:
% <TAB>
but not any of these:
% command <TAB>
% env X=Y <TAB>
% rsync -e <TAB>
⋮
Messages sorted by:
Reverse Date,
Date,
Thread,
Author