aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Spencer <idlemoor@slackbuilds.org>2016-01-16 19:31:54 +0000
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2016-01-17 09:27:24 +0700
commit8d45192a4044ab2ad3fa8a8f58681bc2c26b24ac (patch)
tree4b54fc4d25412101dc18446455dc235a31cd783e
parentcb728cbf7b91f172149b4862fe83af93f6286097 (diff)
development/npm2tgz: Support alternate tarball name.
Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
-rw-r--r--development/npm2tgz/npm2tgz.SlackBuild7
1 files changed, 3 insertions, 4 deletions
diff --git a/development/npm2tgz/npm2tgz.SlackBuild b/development/npm2tgz/npm2tgz.SlackBuild
index 88b06a8dcc10..3ceb1be8f3df 100644
--- a/development/npm2tgz/npm2tgz.SlackBuild
+++ b/development/npm2tgz/npm2tgz.SlackBuild
@@ -11,8 +11,6 @@ TAG=${TAG:-_SBo}
ARCH=noarch
-SRCNAM="$VERSION.tar.gz"
-
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
@@ -20,10 +18,11 @@ OUTPUT=${OUTPUT:-/tmp}
set -e
-rm -rf $TMP/$PRGNAM-$VERSION $PKG
+rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
-tar xvf $CWD/$SRCNAM
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$VERSION.tar.gz || tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root.root .
find -L . \