summaryrefslogtreecommitdiff
path: root/rc
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@localhost>2011-06-26 07:03:44 +0200
committercinap_lenrek <cinap_lenrek@localhost>2011-06-26 07:03:44 +0200
commitfff6d18d5135b5a5580e5ea842958114325a508d (patch)
treec8912870339621b883202c574cb944d7f4115e24 /rc
parentbc1ff6985c03402497a052d2b4e2a299b3cdf218 (diff)
parent883f9aaab94bddbc21be7675e4889489ce489ec6 (diff)
downloadplan9front-fff6d18d5135b5a5580e5ea842958114325a508d.tar.xz
merge
Diffstat (limited to 'rc')
-rwxr-xr-xrc/bin/kill6
1 files changed, 5 insertions, 1 deletions
diff --git a/rc/bin/kill b/rc/bin/kill
index def927e92..e8ea70ac6 100755
--- a/rc/bin/kill
+++ b/rc/bin/kill
@@ -1,4 +1,8 @@
#!/bin/rc
+rfork e
+U=`{cat /dev/user}
for(i){
- ps | sed -n '/ '^$i^'$/s%^[^ ]* *([^ ]*).*%chmod 666 /proc/\1/ctl;echo kill > /proc/\1/ctl%p'
+ ps | sed -n '/^'$U' .* '$i'$/s%[^ ]* *%~>/proc/%
+ s% *.* (.*)%/note # \1%
+ s%~%echo kill%p'
}