Commit 70d19c7c authored by Richard Torenvliet's avatar Richard Torenvliet

Removed the prefix of tar to determine the extraction method

parent ddfcdc0a
......@@ -40,15 +40,14 @@ function extract() {
if [ -f $ARCHIVE ] ; then
case $ARCHIVE in
*.tar.bz2) tar xvjf $ARCHIVE -C $OUTPUT;;
*.tar.gz) tar xvzf $ARCHIVE -C $OUTPUT;;
*.bz2) tar xvjf $ARCHIVE -C $OUTPUT;;
*.gz) tar xvzf $ARCHIVE -C $OUTPUT;;
*.rar) unrar x $ARCHIVE $OUTPUT ;;
*.tar) tar xvf $ARCHIVE -C $OUTPUT;;
*.tbz2) tar xvjf $ARCHIVE -C $OUTPUT;;
*.tgz) tar xvzf $ARCHIVE -C $OUTPUT;;
*.tbz2) tar xvjf $ARCHIVE -C $OUTPUT;;
*.rar) unrar x $ARCHIVE $OUTPUT;;
*.tar) tar xvf $ARCHIVE -C $OUTPUT;;
*.zip) unzip $ARCHIVE -d $OUTPUT;;
*) echo "'$ARCHIVE' cannot be extracted via >extract<" && exit 1;;
*) echo "'$ARCHIVE' cannot be extracted via >extract<"
esac
else
echo "'$ARCHIVE' is not a valid file $OUTPUT, continueing"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment