diff options
author | rsc <devnull@localhost> | 2006-07-23 14:41:55 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2006-07-23 14:41:55 +0000 |
commit | 5fa0329137c65d51d2ee14fa58eea07f139cf7c3 (patch) | |
tree | 8b0c403af9109440a145f83aac90fcc419e452cb /dist | |
parent | 32a580f43cdd51e6b9bbeda91d905cecf3bd68ec (diff) | |
download | plan9port-5fa0329137c65d51d2ee14fa58eea07f139cf7c3.tar.gz plan9port-5fa0329137c65d51d2ee14fa58eea07f139cf7c3.tar.bz2 plan9port-5fa0329137c65d51d2ee14fa58eea07f139cf7c3.zip |
better status
Diffstat (limited to 'dist')
-rw-r--r-- | dist/isum.awk | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/dist/isum.awk b/dist/isum.awk index cb29eb31..476c6ea9 100644 --- a/dist/isum.awk +++ b/dist/isum.awk @@ -10,21 +10,22 @@ BEGIN { updates = "/dev/stderr" } -function clearstatus( i) +function clearstatus( noflush, i) { if(!updates) return for(i=0; i<statuslen; i++) printf("\b \b") >updates statuslen = 0 - fflush(updates) + if(!noflush) + fflush(updates) } function status(s) { if(!updates) return - clearstatus() + clearstatus(1) printf(" %s ", s) >updates statuslen = length(s)+5 fflush(updates) @@ -75,6 +76,12 @@ debug!=0 { print "# " $0 } next } +/^cd .+; mk .+/ && !verbose { + dir = $2 + sub(/;$/, "", dir) + status(dir " mk " $4) +} + /^cd / { if(debug) print "% cd" errors = 0 @@ -86,11 +93,6 @@ debug!=0 { print "# " $0 } fflush(copy) } } - else{ - dir = $2 - sub(/;$/, "", dir) - status(dir) - } cd = $0 "\n" cmd = "" next |