142
by Scott Moser
add 'make-dist-tarball' just for making a clean tarfile from a tag |
1 |
#!/bin/sh
|
2 |
||
3 |
Usage() { |
|
4 |
cat <<EOF
|
|
5 |
Usage: ${0##*/} version
|
|
6 |
make a tarball of 'version'
|
|
7 |
must be in a bzr directory, and 'version' must be a tag
|
|
8 |
||
9 |
EOF
|
|
10 |
}
|
|
11 |
||
12 |
topdir=$PWD |
|
13 |
tag=${1} |
|
14 |
||
15 |
[ -n "$tag" ] || { Usage 1>&2 ; exit 1; } |
|
16 |
||
17 |
tmpd=$(mktemp -d ); |
|
18 |
trap "rm -Rf '${tmpd}'" 0 |
|
19 |
||
147
by Scott Moser
more removal of 'ec2init' string, replacement with cloud-init |
20 |
out=${topdir}/cloud-init_${tag}.orig.tar.gz |
142
by Scott Moser
add 'make-dist-tarball' just for making a clean tarfile from a tag |
21 |
|
22 |
cd ${tmpd} && |
|
181
by Scott Moser
[packaging] change make-dist-tarball to use the tag given to it |
23 |
bzr branch -r "tag:${tag}" "${topdir}" ./cloud-init-${tag} && |
147
by Scott Moser
more removal of 'ec2init' string, replacement with cloud-init |
24 |
tar czf "${out}" cloud-init-${tag}/ --exclude cloud-init-${tag}/.bzr && |
142
by Scott Moser
add 'make-dist-tarball' just for making a clean tarfile from a tag |
25 |
echo "wrote ${out}" |