Skip to content

Commit 9fe8dbb

Browse files
committed
always use HEAD reference for generating Debian tarball
1 parent 854aae1 commit 9fe8dbb

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

debian/gbp.conf

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,9 @@ prebuild = bash -c "
1111
# Determine list of embedded sources to exclude from Debian source package
1212
zlib_filter_files=\"$(find src/zlib-* -mindepth 1 -maxdepth 1 \! -name zconf.h.in -printf "mongo-c-driver-\${upstream_version}/%p ")\" &&
1313
zlib_rm_files=\"$(find src/zlib-* -mindepth 1 -maxdepth 1 \! -name zconf.h.in -printf '%p ')\" &&
14-
# Determine if we are on a release branch and set the reference to use later
15-
# to create the upstream tarball (when on a release branch use the most
16-
# recent release tag, and when on any other branch use HEAD)
17-
release_branch=$(cd $GBP_GIT_DIR/..; git symbolic-ref --short HEAD | sed -n '/^r[0-9]\./p') &&
18-
if [ -n \"\${release_branch}\" ]; then archive_ref=$(cd $GBP_GIT_DIR/..; git describe --tags --abbrev=0 --match '1.*'); else archive_ref=HEAD; fi &&
1914
# Create upstream tarball from reference, exclude items that do not belong
2015
pushd $GBP_GIT_DIR/.. &&
21-
git archive --format=tar --prefix=mongo-c-driver-\${upstream_version}/ \${archive_ref} | tar -f - --delete mongo-c-driver-\${upstream_version}/debian \$zlib_filter_files | gzip > $GBP_BUILD_DIR/../mongo-c-driver_\${upstream_version}.orig.tar.gz &&
16+
git archive --format=tar --prefix=mongo-c-driver-\${upstream_version}/ HEAD | tar -f - --delete mongo-c-driver-\${upstream_version}/debian \$zlib_filter_files | gzip > $GBP_BUILD_DIR/../mongo-c-driver_\${upstream_version}.orig.tar.gz &&
2217
popd &&
2318
rm -rf \$zlib_rm_files"
2419

0 commit comments

Comments
 (0)