From b3aae857eae46b5e3c610e3a1be338e3eca5882c Mon Sep 17 00:00:00 2001 From: Packet Please Date: Thu, 7 Nov 2024 01:54:22 +0100 Subject: [PATCH 1/2] build: save diskspace by moving instead of copying Many buildbot workers are on ramdisks and don't have unlimited supply. --- build/build.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/build.sh b/build/build.sh index 280ab02..9fbbf46 100755 --- a/build/build.sh +++ b/build/build.sh @@ -258,6 +258,7 @@ EOF |& tee "$destdir/build.log" >&2 -find "$ibdir/bin/targets/$target" \( -name '*.bin' -or -name '*.img' -or -name '*.gz' -or -name 'profiles.json' -or -name 'faillogs' \) -exec cp -avx '{}' "$destdir/" \; +find "$ibdir/bin/targets/$target" \( -name '*.bin' -or -name '*.img' -or -name '*.gz' -or -name 'profiles.json' \) -exec mv -v '{}' "$destdir/" \; +mv "$ibdir/bin/targets/$target/faillogs" "$destdir/" echo "Done." From 5ca94be72b97e76583077767a10430411bbe0626 Mon Sep 17 00:00:00 2001 From: Packet Please Date: Thu, 7 Nov 2024 02:45:24 +0100 Subject: [PATCH 2/2] make fmt --- build/build.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/build/build.sh b/build/build.sh index 9fbbf46..ed76016 100755 --- a/build/build.sh +++ b/build/build.sh @@ -250,14 +250,13 @@ EOF # if build resulted in image files, we can delete the log cnt="$(find "bin/targets/$target" -name '*.bin' -or -name '*.img' -or -name '*.gz' | wc -l)" - if [ "$cnt" -gt 0 ] ; then + if [ "$cnt" -gt 0 ]; then rm -v "bin/targets/$target/faillogs/$p.log" fi done ) \ |& tee "$destdir/build.log" >&2 - find "$ibdir/bin/targets/$target" \( -name '*.bin' -or -name '*.img' -or -name '*.gz' -or -name 'profiles.json' \) -exec mv -v '{}' "$destdir/" \; mv "$ibdir/bin/targets/$target/faillogs" "$destdir/"