offload-build: remove empty src dir when SRCDEST is set
Right now there is a bug in makepkg that leaves back an empty src directory if SRCDEST is set. This is purely cosmetic, but lets just politely try to rmdir it and fail silently if its empty or non-existent. Signed-off-by: Levente Polyak <anthraxx@archlinux.org>
This commit is contained in:
parent
6fffbfbc8a
commit
20eec484fa
|
@ -88,6 +88,10 @@ trap 'rm -rf $SRCPKGDEST' EXIT INT TERM QUIT
|
|||
export SRCPKGDEST=$(mktemp -d)
|
||||
makepkg --source || die "unable to make source package"
|
||||
|
||||
# Temporary cosmetic workaround makepkg if SRCDEST is set somewhere else
|
||||
# but an empty src dir is created in PWD. Remove once fixed in makepkg.
|
||||
rmdir --ignore-fail-on-non-empty src 2>/dev/null || true
|
||||
|
||||
mapfile -t files < <(
|
||||
# This is sort of bash golfing but it allows running a mildly complex
|
||||
# command over ssh with a single connection.
|
||||
|
|
Loading…
Reference in New Issue