Add check for successfull unpack
This commit is contained in:
parent
12eb408429
commit
ec7f9e20bd
|
@ -15,8 +15,12 @@ cd /mnt/beacon_data
|
||||||
echo "Unpacking the data"
|
echo "Unpacking the data"
|
||||||
tar -I zstd -xvf *.tar.zst
|
tar -I zstd -xvf *.tar.zst
|
||||||
|
|
||||||
echo "Deleting the tar.zst"
|
if [ $? -eq 0 ]; then
|
||||||
rm *.tar.zst
|
echo "Deleting the tar.zst"
|
||||||
|
rm *.tar.zst
|
||||||
|
else
|
||||||
|
echo "Tar command failed. Not deleting the tar.zst file."
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
if [ -n "$DEBUG" ]; then
|
if [ -n "$DEBUG" ]; then
|
||||||
|
|
Loading…
Reference in New Issue