chore: Update disk-setup-and-swap.sh to conditionally execute 'free -h' and 'df -h' commands

This commit is contained in:
Mauro Balades
2024-07-23 13:46:32 +02:00
parent 1bcd4021dd
commit 85b76f525c

View File

@@ -1,7 +1,11 @@
echo Before:
free -h
df -h
if [ command -v free ]; then
free -h
fi
if [ command -v df ]; then
df -h
fi
echo
echo
@@ -38,5 +42,9 @@ echo
echo
echo After:
free -h
df -h
if [ command -v free ]; then
free -h
fi
if [ command -v df ]; then
df -h
fi