[packages/chromium-browser] add missing unpack() method
glen
glen at pld-linux.org
Tue Dec 11 22:56:17 CET 2012
commit 967f897700bceb1079fe8127495021056808f21a
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Tue Dec 11 23:54:51 2012 +0200
add missing unpack() method
make-diff-patch.sh | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
---
diff --git a/make-diff-patch.sh b/make-diff-patch.sh
index c32e161..e7845b5 100755
--- a/make-diff-patch.sh
+++ b/make-diff-patch.sh
@@ -4,6 +4,25 @@ src=$1
dst=$2
ext=.tar.xz
+unpack() {
+ case "$1" in
+ *.tgz|*.tar.[Zz]|*.tar.gz) tar zx${verbose:+v}f "$1" ;;
+ *.tar) tar x${verbose:+v}f "$1" ;;
+ *.tbz2|*.tbz|*.tar.bz2) tar jx${verbose:+v}f "$1" ;;
+ *.tar.xz) xz -dc "$1" | tar x${verbose:+v} ;;
+ *.tar) tar x${verbose:+v}f "$1" ;;
+ *)
+ echo >&2 "Don't know how to unpack $1"
+ return 1
+ ;;
+ esac
+}
+
+# unpack all sources in commandline
+for a in "$@"; do
+ unpack "$a"
+done
+
set -e
srcdir=$(basename $src $ext)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/chromium-browser.git/commitdiff/967f897700bceb1079fe8127495021056808f21a
More information about the pld-cvs-commit
mailing list