fix(ci): drop the bad gh-mirror/ rsync exclude (it blocked --delete cleanup)
CI / check (pull_request) Successful in 6s

rsync's --exclude also protects the matching path at the DESTINATION from
--delete. The belt-and-suspenders --exclude='gh-mirror/' I added in the previous
fix prevented the stray gh-mirror/ subtree at the destination from ever being
deleted by --delete, defeating the auto-heal. The structural fix (cloning the
GitHub mirror into $RUNNER_TEMP, outside ./) already prevents the recursive
self-include, so the exclude is unnecessary and harmful. Removed it; left an
explanatory NOTE in the workflow so this isn't re-added.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TfzV5QvtPDz8LJS3Pu5VLT
This commit is contained in:
2026-06-24 21:43:22 -04:00
parent c46715b811
commit 5286114acb
+4 -2
View File
@@ -53,14 +53,16 @@ jobs:
# Mirror this checkout's tree into gh-mirror/ with the exclusions.
# --delete drops files removed on the source; --exclude='.git' protects
# both repos' .git dirs from rsync touching them.
# belt-and-suspenders exclude of the clone dir name in case anyone re-uses ./gh-mirror.
# NOTE: do NOT add an --exclude for the clone target dir name; rsync's --exclude also
# protects the matching path at the DESTINATION from --delete, which would prevent
# any stray copy of that dir from ever being cleaned up. The clone living in
# $RUNNER_TEMP (outside ./) already prevents the recursive self-include.
rsync -a --delete \
--exclude='.git' \
--exclude='.gitea/' \
--exclude='.claude/' \
--exclude='blog/' \
--exclude='handoff.md' \
--exclude='gh-mirror/' \
--exclude='__pycache__/' \
--exclude='*.pyc' \
--exclude='tasks.json' \