make-disk-image: fix pre/post files with empty glob

This commit is contained in:
lassulus 2023-09-22 11:11:03 +02:00 committed by mergify[bot]
parent dd142cd8a2
commit 98a6ab9b52

View file

@ -122,6 +122,7 @@ in
set -eu
export PATH=${lib.makeBinPath dependencies}
for src in /tmp/xchg/copy_before_disko/*; do
[ -e "$src" ] || continue
dst=$(basename "$src" | base64 -d)
mkdir -p "$(dirname "$dst")"
cp -r "$src" "$dst"
@ -129,7 +130,8 @@ in
set -f
${builder}
set +f
for dir in /tmp/xchg/copy_after_disko/*; do
for src in /tmp/xchg/copy_after_disko/*; do
[ -e "$src" ] || continue
dst=/mnt/$(basename "$src" | base64 -d)
mkdir -p "$(dirname "$dst")"
cp -r "$src" "$dst"