From 333b8f404b8e9716513558a0787d7b50d26afde0 Mon Sep 17 00:00:00 2001 From: Jakub Ružička Date: Tue, 23 May 2023 13:42:28 +0200 Subject: scripts: improve make-archive.sh script Copy resulting tarball into pkg/archives/dev and delete build_dist/ dir to keep working copy clean. --- scripts/make-archive.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/make-archive.sh b/scripts/make-archive.sh index 82703674..b9d00aa4 100755 --- a/scripts/make-archive.sh +++ b/scripts/make-archive.sh @@ -33,6 +33,14 @@ rm -rf build_dist ||: meson build_dist ninja -C build_dist dist -# print path to generated tarball -set +o xtrace -find "${PWD}/build_dist/meson-dist/" -name "knot-resolver-*.tar.xz" +# copy tarball to apkg path +DIST_ARCHIVE=$(find "build_dist/meson-dist/" -name "knot-resolver-*.tar.xz") +APKG_ARCHIVE="pkg/archives/dev/$(basename $DIST_ARCHIVE)" +mkdir -p pkg/archives/dev +cp "$DIST_ARCHIVE" "$APKG_ARCHIVE" + +# remove build directory +rm -rf build_dist ||: + +# print path to generated tarball as expected by apkg +echo "$APKG_ARCHIVE" -- cgit v1.2.3