Only format ESP if no file is specified

This commit is contained in:
Ollo
2021-01-31 20:41:03 +01:00
parent f72295e709
commit f93d0df461
2 changed files with 12 additions and 8 deletions

View File

@@ -32,12 +32,14 @@ else
fi
# Format filesystem first
echo "Format the complete ESP"
python3 $LUATOOL -p $DEVICE -w -b $BAUD
if [ $? -ne 0 ]; then
echo "STOOOOP"
exit 1
if [ $# -eq 1 ]; then
# Format filesystem first
echo "Format the complete ESP"
python3 $LUATOOL -p $DEVICE -w -b $BAUD
if [ $? -ne 0 ]; then
echo "STOOOOP"
exit 1
fi
fi
#stty -F $DEVICE $BAUD