allow kill of pids. recognize -sig.

This commit is contained in:
rsc 2005-01-04 21:14:29 +00:00
parent ead3e31153
commit f9bca6a2a4

View file

@ -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