diff --git a/storage-test.sh b/storage-test.sh index c1f0fb1..48af1cf 100755 --- a/storage-test.sh +++ b/storage-test.sh @@ -107,11 +107,9 @@ if [ "$1" = "" ]; then # User did not provide a partition/folder, change directory to rootfs df=0 drives="$(df | grep ext4)" - IFS=' - ' - for d in "${drives}"; do - ((df++)) - echo "${df}) ${d}" + echo "$drives" | while IFS= read -r line ; do + (($df++)) + echo "$df) $line" done exit 0