Update storage-test.sh
This commit is contained in:
@@ -104,16 +104,18 @@ IO4kRandWrite=0
|
|||||||
# Did the user give a folder ?
|
# Did the user give a folder ?
|
||||||
ChosenPartition=""
|
ChosenPartition=""
|
||||||
if [ "$1" = "" ]; then
|
if [ "$1" = "" ]; then
|
||||||
df=0; declare -A driveSel
|
echo
|
||||||
echo "$(/bin/df -kTh | grep ext4)" | while IFS= read -r line ; do
|
Print_Style "Select a partition to test from:" "$YELLOW"
|
||||||
((df++))
|
df=0; declare -A driveSel
|
||||||
path=$(echo $line | cut -d'%' -f2)
|
echo "$(/bin/df -kTh | grep ext4)" | while IFS= read -r line ; do
|
||||||
driveSel["${df}"] = "${path// }"
|
((df++))
|
||||||
echo "$df) ${path// }"
|
path=$(echo $line | cut -d'%' -f2)
|
||||||
done
|
driveSel["${df}"] = "${path// }"
|
||||||
|
Print_Style "$df) ${path// }" "$BLUE"
|
||||||
exit 0
|
done
|
||||||
cd /
|
|
||||||
|
exit 0
|
||||||
|
cd \
|
||||||
else
|
else
|
||||||
if [ ! -d "$1" ]; then
|
if [ ! -d "$1" ]; then
|
||||||
Print_Style "Your chosen partition (folder) does not exist! Provide a good one or run without parameters to check the rootfs" "$RED"
|
Print_Style "Your chosen partition (folder) does not exist! Provide a good one or run without parameters to check the rootfs" "$RED"
|
||||||
|
|||||||
Reference in New Issue
Block a user