From 99e5150f811412e50e7dfb5626a432ea684bcd5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Claude=20=28=E6=9C=AC=E6=A9=9F=E7=B8=BD=E7=AE=A1=29?= Date: Sat, 18 Jul 2026 23:29:33 +0800 Subject: [PATCH] =?UTF-8?q?feat(publish):=20sanitize=20=E9=89=A4=E5=AD=90(?= =?UTF-8?q?=E5=90=8C=E6=AD=A5)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/publish-github.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scripts/publish-github.sh b/scripts/publish-github.sh index 9fcab17..db123e4 100755 --- a/scripts/publish-github.sh +++ b/scripts/publish-github.sh @@ -39,6 +39,11 @@ while IFS= read -r p; do rm -rf "${TMP_EXPORT:?}/$p" done < "$EXCLUDE_FILE" +# 3.5) repo 自備的遮蔽腳本(可選):對匯出樹做內容級遮蔽(如指南去帳密) +if [ -f "$REPO_ROOT/scripts/github-publish-sanitize.py" ]; then + python3 "$REPO_ROOT/scripts/github-publish-sanitize.py" "$TMP_EXPORT" +fi + # 4) 同步進常駐 mirror(mirror 自己的 .git = 公開端乾淨歷史) mkdir -p "$MIRROR_DIR" [ -d "$MIRROR_DIR/.git" ] || git -C "$MIRROR_DIR" init -q -b main