diff options
author | Vlastimil Holer <vlastimil.holer@gmail.com> | 2013-09-05 13:11:09 +0200 |
---|---|---|
committer | Vlastimil Holer <vlastimil.holer@gmail.com> | 2013-09-05 13:11:09 +0200 |
commit | 744c779182cba32314f8435660a61c2711cb9f54 (patch) | |
tree | 7871342bf0b122217b51493286bac982313b48da /tools/make-tarball | |
parent | 8a2a88e0bb4520eabe99b6686413a548f3d59652 (diff) | |
parent | 1d27cd75eaaeef7b72f3be77de24da815c82a825 (diff) | |
download | vyos-cloud-init-744c779182cba32314f8435660a61c2711cb9f54.tar.gz vyos-cloud-init-744c779182cba32314f8435660a61c2711cb9f54.zip |
Merged trunk lp:cloud-init
Diffstat (limited to 'tools/make-tarball')
-rwxr-xr-x | tools/make-tarball | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/tools/make-tarball b/tools/make-tarball index 47979f5b..27f5f374 100755 --- a/tools/make-tarball +++ b/tools/make-tarball @@ -18,18 +18,16 @@ if ! find_root; then exit 1; fi +REVNO=$(bzr revno "$ROOT_DIR") + if [ ! -z "$1" ]; then ARCHIVE_FN="$1" else - REVNO=$(bzr revno $ROOT_DIR) - VERSION=$($ROOT_DIR/tools/read-version) + VERSION=$("$ROOT_DIR/tools/read-version") ARCHIVE_FN="$PWD/cloud-init-$VERSION~bzr$REVNO.tar.gz" fi -FILES=$(cd $ROOT_DIR && bzr ls --versioned --recursive) -echo "$FILES" | tar czf $ARCHIVE_FN \ - -C "$ROOT_DIR" \ - --transform "s,^,cloud-init-$VERSION~bzr$REVNO/," \ - --no-recursion --files-from - +bzr export --format=tgz --root="cloud-init-$VERSION~bzr$REVNO" \ + "--revision=${REVNO}" "${ARCHIVE_FN}" "$ROOT_DIR" echo "$ARCHIVE_FN" |