Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] Completion: Add _bash, update _sh
- X-seq: zsh-workers 42966
- From: dana <dana@xxxxxxx>
- To: Zsh workers <zsh-workers@xxxxxxx>
- Subject: Re: [PATCH] Completion: Add _bash, update _sh
- Date: Sat, 9 Jun 2018 00:44:01 -0500
- Cc: dana <dana@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dana-is.20150623.gappssmtp.com; s=20150623; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=MTZ4w6dekUKmNOBT5LqMXadT8bbbC+Jhpr/k07D5veo=; b=pNHH6GrOIjoz6uFrfu+llT/Z55ubq376G64KQFkax0ybmj0jyMGk3i2GvaDEsb6RE7 AuEQfmcD6HFz8Mh0slbklXpYqV8UfU+cwgaq+NWxkEQ7iNXIzeGZ3DcS2bFb2ZcuqdAF dlF0O2rO2UvVV4BkQIhawdSfiFnu0c2aNW3Q/9f5LkmCxTu33FRzJMWD+gCoQNucEzIl TO5GAOy3aNGAMNkqQTVU9ZkE4Kyu5+Vyi5OLmFUjPCAd1hWmmuZ9NePgS/CtLhmA6OVV eFfyTO24uMyz3WqP3KxNY/sNCQwTjW376fGMxs+LuRLbKUbDBrQDQcwPZL/g1jcjAw+r Vyag==
- In-reply-to: <52421D97-B114-45A1-B547-30F4D6DAE162@dana.is>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <52421D97-B114-45A1-B547-30F4D6DAE162@dana.is>
Oh, PPPS:
On 9 Jun 2018, at 00:15, dana <dana@xxxxxxx> wrote:
>+ args)
>+ if [[ -n ${opt_args[(i)s--[cs]]} ]]; then
>+ _files && ret=0
>+ else
>+ _normal && ret=0
>+ fi
>+ ;;
I wanted to mention (and probably should have in a comment) that my thinking
here was that you might do something like `bash /usr/bin/mycmd <tab>` and then
if mycmd had completion you'd want it handled as normal. On balance, it's
probably not *super* common for someone to explicitly call bash to execute a
script that has completion, so this might be undesirable — it'll cause custom
scripts that just happen to have the same name as a more popular command to be
completed as that command. So it could be preferable to just have an
unconditional '(-)*:: :_files' or whatever.
I don't feel strongly either way; feel free to edit if you do.
dana
Messages sorted by:
Reverse Date,
Date,
Thread,
Author