ab14e0f
#!/bin/bash
ab14e0f
db28cc1
tag=1.1.4
ab14e0f
ab14e0f
set -e
ab14e0f
ab14e0f
tmp=$(mktemp -d)
ab14e0f
ab14e0f
trap cleanup EXIT
ab14e0f
cleanup() {
ab14e0f
    set +e
ab14e0f
    [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp"
ab14e0f
}
ab14e0f
ab14e0f
unset CDPATH
ab14e0f
pwd=$(pwd)
ab14e0f
ab14e0f
pushd "$tmp"
ab14e0f
git clone git://github.com/stream-utils/raw-body.git
ab14e0f
cd raw-body
ab14e0f
git archive --prefix="test/" --format=tar tags/${tag}:test/ \
ab14e0f
    | bzip2 > "$pwd"/tests-${tag}.tar.bz2
ab14e0f
popd