zsh-workers
 help / color / mirror / code / Atom feed
From: "Jun T." <takimoto-j@kba.biglobe.ne.jp>
To: zsh-workers@zsh.org
Subject: Re: [PATCH] rewrite _killall
Date: Mon, 2 Jul 2018 01:17:02 +0900	[thread overview]
Message-ID: <6E41F2AE-E723-4BD5-9507-1FB24AF76C40@kba.biglobe.ne.jp> (raw)
In-Reply-To: <7EC1FE8D-1B43-4EC2-A787-FC51E5202341@dana.is>


> 2018/06/28 23:52、dana <dana@dana.is>のメール:
> On 28 Jun 2018, at 02:39, Jun T <takimoto-j@kba.biglobe.ne.jp> wrote:
>> +  _arguments -s -S : $args
> 
> `-A '-*'` would be appropriate for this one.

I didn't add this because "killall -SIGNAL -<TAB>" does not complete
options if -A '-*' is included.
If we do not want to complete options after process names, something
like the following (patch to my previous patch) may be necessary.
A problem of this is now users can't customize by tag-order.


diff --git a/Completion/Unix/Command/_killall b/Completion/Unix/Command/_killall
index a62181c25..d603e6e4a 100644
--- a/Completion/Unix/Command/_killall
+++ b/Completion/Unix/Command/_killall
@@ -69,9 +69,9 @@ else # bsd and darwin
     '-t[limit to processes running on specified tty]: :_ttys -od'
     "-c[with -u or -t, limit to processes matching specified name]: :_process_names $opts"
     '-z[do not skip zombies]'
-    "1: : _alternative 'signals::_signals -p' 'processes-names::_process_names $opts'"
     "*: :_process_names $opts"
+    + '(signal)' -$signals[2,-3]
   )
-  _arguments -s -S : $args
+  _arguments -s -S -A '-*' : $args
 
 fi


  parent reply	other threads:[~2018-07-01 16:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-28  7:39 Jun T
2018-06-28 13:10 ` Jun T.
2018-06-28 14:52 ` dana
2018-06-29 11:45   ` Jun T
2018-07-01 16:17   ` Jun T. [this message]
2018-07-01 19:14     ` dana

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6E41F2AE-E723-4BD5-9507-1FB24AF76C40@kba.biglobe.ne.jp \
    --to=takimoto-j@kba.biglobe.ne.jp \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).