From 4dfbf9ad3eea3c4683373e55ae3d0ba91c68eee1 Mon Sep 17 00:00:00 2001 From: Harald Sitter Date: Wed, 6 Nov 2024 22:56:40 +0100 Subject: [PATCH] clean up the split partitions otherwise we end up publishing them --- part-rebuild.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/part-rebuild.py b/part-rebuild.py index 0d42373..ea4a765 100755 --- a/part-rebuild.py +++ b/part-rebuild.py @@ -38,3 +38,7 @@ for index, partition in enumerate(partitions): # Then reassemble them into a new image using those squeezed partition images. open(RAW, "w").close() subprocess.run(["systemd-repart", "--size=auto", "--empty=allow", "--dry-run=no", "--definitions=mkosi.repart-rebuild", "--root", os.getcwd(), RAW], check=True) + +# Clean up the partitions again +for partition in partitions: + os.remove(f"{partition["name"]}.raw")