diff options
author | rsc <devnull@localhost> | 2005-01-04 21:14:29 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-01-04 21:14:29 +0000 |
commit | f9bca6a2a402eca55bcd8ea3f17d0051d7b5382e (patch) | |
tree | f9335454d55653f3738285ee3d4f5b1d4707caaa /bin/kill | |
parent | ead3e31153b4258073dd16f990e0bc1842646562 (diff) | |
download | plan9port-f9bca6a2a402eca55bcd8ea3f17d0051d7b5382e.tar.gz plan9port-f9bca6a2a402eca55bcd8ea3f17d0051d7b5382e.tar.bz2 plan9port-f9bca6a2a402eca55bcd8ea3f17d0051d7b5382e.zip |
allow kill of pids. recognize -sig.
Diffstat (limited to 'bin/kill')
-rwxr-xr-x | bin/kill | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -1,6 +1,14 @@ #!/bin/sh +sig="" +case "$1" in +-*) + sig=" $1" + shift + ;; +esac + for i do - psu | awk '$NF ~ /^('$i')$/ {printf("/bin/kill %d # %s\n", $2, $0);}' + psu | awk '$NF == "'"$i"'" || $2 == "'"$i"'" {printf("/bin/kill%s %d # %s\n", "'"$sig"'", $2, $0);}' done |