summaryrefslogtreecommitdiffstats
path: root/python-slacker-generate-tests-tarball.sh
diff options
context:
space:
mode:
authorKen Dreyer <ktdreyer@ktdreyer.com>2015-01-29 23:25:22 -0700
committerKen Dreyer <ktdreyer@ktdreyer.com>2015-01-29 23:25:25 -0700
commit8e00684f09b3c097c52799d36f74907e9f1665ca (patch)
tree855b358351a9e53904e632a0a29a814357ff5a80 /python-slacker-generate-tests-tarball.sh
downloadpython-slacker-master.zip
python-slacker-master.tar.gz
python-slacker-master.tar.xz
initial package importHEADmaster
Diffstat (limited to 'python-slacker-generate-tests-tarball.sh')
-rwxr-xr-xpython-slacker-generate-tests-tarball.sh26
1 files changed, 26 insertions, 0 deletions
diff --git a/python-slacker-generate-tests-tarball.sh b/python-slacker-generate-tests-tarball.sh
new file mode 100755
index 0000000..4b043cf
--- /dev/null
+++ b/python-slacker-generate-tests-tarball.sh
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+set -e
+
+VERSION=0.5.4
+
+GITHUBURL=https://github.com/os/slacker/archive/v${VERSION}.zip
+
+# download zipball
+if [[ ! -f slacker-$VERSION.zip ]]; then
+ curl -o slacker-$VERSION.zip -L $GITHUBURL
+fi
+
+# extract zipball
+[[ -d slacker-$VERSION ]] && rm -r slacker-$VERSION
+unzip slacker-$VERSION.zip
+
+pushd slacker-$VERSION
+ # repack
+ tar -cJvf slacker-$VERSION-tests.tar.xz tests
+ mv slacker-$VERSION-tests.tar.xz ..
+popd
+
+# Clean up
+rm slacker-$VERSION.zip
+rm -r slacker-$VERSION