diff options
author | rsc <devnull@localhost> | 2005-10-19 03:15:30 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-10-19 03:15:30 +0000 |
commit | fc165dcb3eb3f6d5994903ae7f9cb91c9f598cef (patch) | |
tree | 282736afb584c2b001381f180385f11eae8ddeb7 /bin/psu | |
parent | f810f8a5b03247430f1d7b219f83bfe31eaeee02 (diff) | |
download | plan9port-fc165dcb3eb3f6d5994903ae7f9cb91c9f598cef.tar.gz plan9port-fc165dcb3eb3f6d5994903ae7f9cb91c9f598cef.tar.bz2 plan9port-fc165dcb3eb3f6d5994903ae7f9cb91c9f598cef.zip |
Autoframework (Jeff Sickel)
Diffstat (limited to 'bin/psu')
-rwxr-xr-x | bin/psu | 21 |
1 files changed, 20 insertions, 1 deletions
@@ -19,4 +19,23 @@ case $# in exit 1 esac -9 ps $flag | grep "^$user " +9 ps $flag | grep "^$user " | awk ' + BEGIN { min = 1000000 }; + { + line[0+nline++] = $0; + n = length; + sub(/ +/, "", $0); + n -= length; + if(n < min) + min = n; + } + END{ + s = ""; + for(i=0; i<min-1; i++) + s = s " "; + for(i=0; i<nline; i++){ + sub(s, "", line[i]) + print line[i] + } + } +' |