X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Farchival%2Funpack.sh;h=b67ac9788a56eaabbf00af64ac58bc3e2e35cdad;hb=75c90aed778caf39226407e17519efd0e5028237;hp=3fca182d2f9ae1fbc311bd664191e58960582f6b;hpb=a032348bd89b392e64fd19a409479fa78e9c583d;p=feisty_meow.git diff --git a/scripts/archival/unpack.sh b/scripts/archival/unpack.sh index 3fca182d..b67ac978 100644 --- a/scripts/archival/unpack.sh +++ b/scripts/archival/unpack.sh @@ -30,7 +30,7 @@ if [ -z "$unpack_dir" ]; then fi if [ ! -d "$unpack_dir" ]; then - mkdir "$unpack_dir" + mkdir -p "$unpack_dir" if [ $? -ne 0 ]; then echo "Could not create the unpacking directory: $unpack_dir" exit 1 @@ -62,9 +62,12 @@ save_err=1 if [[ "$archive_file" =~ .*\.tar$ \ || "$archive_file" =~ .*\.tar\.gz$ \ || "$archive_file" =~ .*\.tar\.bz2$ \ + || "$archive_file" =~ .*\.tar\.xz$ \ || "$archive_file" =~ .*\.iar$ \ || "$archive_file" =~ .*\.oar$ \ + || "$archive_file" =~ .*\.tbz$ \ || "$archive_file" =~ .*\.tgz$ \ + || "$archive_file" =~ .*\.txz$ \ || "$archive_file" =~ .*\.ova$ \ || "$archive_file" =~ .*\.snarf$ \ ]]; then @@ -82,7 +85,7 @@ elif [[ "$archive_file" =~ .*\.7z$ ]]; then 7z x "$archive_file" &>/dev/null save_err=$? elif [[ "$archive_file" =~ .*\.rar$ ]]; then - rar x "$archive_file" &>/dev/null + unrar x "$archive_file" &>/dev/null save_err=$? fi