better debugging output

This commit is contained in:
inxi-svn 2009-01-09 02:37:37 +00:00
parent 56df25f401
commit 5904c7604a

11
inxi
View file

@ -1,7 +1,7 @@
#!/bin/bash
########################################################################
#### Script Name: inxi
#### version: 0.9.3-b1-t3
#### version: 0.9.3-b1-t4
#### Date: January 8, 2009
########################################################################
#### SPECIAL THANKS
@ -1881,17 +1881,24 @@ get_hdd_data_basic()
getline
}
if ( $4 ~ /.*\%/ ) {
print "b: " $1 "used: " $2 "full: " $1
used += $2
full += $1
}
else if ( $5 ~ /.*\%/ ) {
print "a: " $1 "used: " $3 "full: " $2
used += $3
full += $2
}
else {
next
}
}
END {
print used
print "used : " used
print "full : " full
percent = used/full
print "percent : " percent
}' )
else
hdd_used=$( df | gawk '