From 53cc0f179f3be97bbdeeba794cbbef3d05d1b72c Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Thu, 7 Jun 2018 14:24:35 +0200 Subject: bin/return-assignment: use file instead of space-separated variable to store built package names --- bin/return-assignment | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'bin/return-assignment') diff --git a/bin/return-assignment b/bin/return-assignment index 0b3744c..3dee115 100755 --- a/bin/return-assignment +++ b/bin/return-assignment @@ -402,9 +402,9 @@ if [ -z "$( fi # check if the sent packages are the expected ones -packages=$( - find . -maxdepth 1 -name '*.pkg.tar.xz' -printf '%f\n' -) +find . -maxdepth 1 -name '*.pkg.tar.xz' -printf '%f\n' > \ + "${tmp_dir}/packages" + # shellcheck disable=SC2016 { printf 'SELECT' @@ -429,10 +429,9 @@ packages=$( package_errors=$( { - printf '%s\n' "${packages}" | \ - sed ' - s|^|was_built: | - ' + sed ' + s|^|was_built: | + ' "${tmp_dir}/packages" sed ' s|^[0-9]\+ |expected: | ' "${tmp_dir}/package-ids" @@ -514,9 +513,10 @@ for arch in 'i686'; do "${master_mirror_rsync_directory}/i686/${destination}/${destination}.files."* \ "${arch}/" - # shellcheck disable=SC2086 - repo-add "${arch}/${destination}.db.tar.gz" ${packages} - # repo-add -v -s -k "${repo_key}" "${destination}.db.tar.gz" ${packages} + xargs -r repo-add "${arch}/${destination}.db.tar.gz" < \ + "${tmp_dir}/packages" + # xargs -r repo-add -v -s -k "${repo_key}" "${destination}.db.tar.gz" < \ + # "${tmp_dir}/packages" done -- cgit v1.2.3-70-g09d2