changed from echo to printf

This commit is contained in:
Andrew Titmuss 2016-03-14 21:33:14 +11:00
parent 34f145b7b1
commit c0a6886dcc

View file

@ -1508,12 +1508,12 @@ getdisk () {
disk_total=${disk_total/G}
if [[ "$disk_used" == *"T" ]]; then
disk_used=$(echo "${disk_used/T} * 1000" | bc)
disk_used=$(printf "%s\n" "${disk_used/T} * 1000" | bc)
disk_used=${disk_used/'.'*}
fi
if [[ "$disk_total" == *"T" ]]; then
disk_total=$(echo "${disk_total/T} * 1000" | bc)
disk_total=$(printf "%s\n" "${disk_total/T} * 1000" | bc)
disk_total=${disk_total/'.'*}
fi