summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMario Fetka <[email protected]>2012-02-18 14:18:46 (GMT)
committer Mario Fetka <[email protected]>2012-02-18 14:18:46 (GMT)
commitc26374d993dc45a9667b2d6b768fef815e215c93 (patch)
treea256ee1626aa8a4e04b2f08ef8ed4de201e6447a
parent088460ba47aed2e5072a0b8863f0dfbf4f8f49a7 (diff)
add unrar support (for broken rar packages not handled by 7zip)
-rw-r--r--lib/builder-targets.sh1
-rw-r--r--lib/builder-utils.sh2
2 files changed, 3 insertions, 0 deletions
diff --git a/lib/builder-targets.sh b/lib/builder-targets.sh
index 500e1c9..5414fa8 100644
--- a/lib/builder-targets.sh
+++ b/lib/builder-targets.sh
@@ -13,6 +13,7 @@ builder_config() {
# Define commands
CMD_7z="`which 7z`" ; builder_check_error "Command '7z' not installed"
CMD_unzip="`which unzip`" ; builder_check_error "Command 'unzip' not installed"
+ CMD_unrar="`which unrar`" ; builder_check_error "Command 'unrar' not installed"
CMD_zip="`which zip`" ; builder_check_error "Command 'zip' not installed"
CMD_unix2dos="`which unix2dos`" ; builder_check_error "Command 'unix2dos' not installed"
CMD_identify="`which identify`" ; builder_check_error "Command 'identify' (ImageMagick) not installed"
diff --git a/lib/builder-utils.sh b/lib/builder-utils.sh
index e96feaa..bb04b87 100644
--- a/lib/builder-utils.sh
+++ b/lib/builder-utils.sh
@@ -60,6 +60,8 @@ function process_file() {
$CMD_7z x -o$dst $src
elif [ "$format" = "unzip" ]; then
$CMD_unzip $src -d $dst
+ elif [ "$format" = "unrar" ]; then
+ $CMD_unrar x $src $dst
else
fatal_error "Unknown compression format: $format"
fi

Powered by Domaintechnik.at | Hosting - Domain - Webspace