lstk: add /bin/lstk to dump most recent crashed proc

This commit is contained in:
Ori Bernstein 2023-08-14 03:50:01 +00:00
parent 2a6e03968b
commit 13b1ea7493

10
rc/bin/lstk Executable file
View file

@ -0,0 +1,10 @@
#!/bin/rc
if(~ $#* 1)
p=$1
if not if(~ $#* 0)
p=`{ps | grep Broken | awk '{print $2}' | sort -n | tail -n 1}
if not
p 'usage: $0 [broken]' >[2=1]
echo 'lstk()' | acid $p