From b2ca2b700da2c3e7b84173402fc9736fb374ebdd Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Sat, 11 Jul 2026 10:56:40 +0200 Subject: Add rsync_excludes helper + self-check Emits one anchored --exclude=// per SBO_PERSONAL_TREES key, so a future rsync-based tree sync never deletes personal/pentesting clones that are not on the sync source. Co-Authored-By: Claude Opus 4.8 --- sbo-batch-test | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'sbo-batch-test') diff --git a/sbo-batch-test b/sbo-batch-test index 5f9695d..a29461b 100755 --- a/sbo-batch-test +++ b/sbo-batch-test @@ -321,6 +321,16 @@ update_base() { echo "Base patched." } +# Echo one anchored `--exclude=//` per SBO_PERSONAL_TREES key, one per +# line. Anchored to the tree root so rsync --delete never wipes a personal +# clone (they are not on the rsync source). Empty when no personal trees. +rsync_excludes() { + local dir + for dir in "${!SBO_PERSONAL_TREES[@]}"; do + echo "--exclude=/$dir/" + done +} + # ============================================================================= # Package cache. Persistent, on-disk store of built packages so unchanged deps # are installed from cache instead of rebuilt. Layout mirrors the SBo tree: -- cgit v1.2.3