update at 2025-10-08 22:26:26

This commit is contained in:
douboer
2025-10-08 22:26:26 +08:00
parent 7b36394427
commit e25dca5fdd
24 changed files with 180 additions and 1485 deletions

View File

@@ -14,6 +14,7 @@ for FILE in "${FILES[@]}"; do
BACKUP="$PLUGIN_DIR/backup/$FILE.bk"
if [ -f "$TARGET" ]; then
mkdir -p "$(dirname "$BACKUP")"
cp -f "$TARGET" "$BACKUP"
echo "已备份 $TARGET -> $BACKUP"
fi
@@ -25,3 +26,12 @@ for FILE in "${FILES[@]}"; do
echo "⚠️ 源文件 $FILE 不存在,跳过"
fi
done
# 4. 覆盖复制 assets 目录(静默)
if [ -d "assets" ]; then
mkdir -p "$PLUGIN_DIR/assets"
rsync -a --delete assets/ "$PLUGIN_DIR/assets/" >/dev/null
echo "已同步 assets -> $PLUGIN_DIR/assets/"
else
echo "⚠️ 源目录 assets 不存在,跳过"
fi