31 lines
921 B
Bash
31 lines
921 B
Bash
#!/bin/bash
|
|
# 수동 비상 sync — 양방향 memory 동기화 강제 실행
|
|
# 사용: bash scripts/sync_memory.sh {both|repo-to-central|central-to-repo}
|
|
# 2026-04-19 신설 — C34-3 동기화 4계층 (수동 비상)
|
|
|
|
DIR_ARG="${1:-both}"
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
|
|
case "$DIR_ARG" in
|
|
repo-to-central)
|
|
echo "▶️ 레포 → 중앙 (단방향)"
|
|
bash "$SCRIPT_DIR/sync_memory_repo_to_central.sh"
|
|
;;
|
|
central-to-repo)
|
|
echo "▶️ 중앙 → 레포 (단방향)"
|
|
bash "$SCRIPT_DIR/sync_memory_central_to_repo.sh"
|
|
;;
|
|
both)
|
|
echo "▶️ 양방향 sync (레포 → 중앙 → 레포)"
|
|
bash "$SCRIPT_DIR/sync_memory_repo_to_central.sh"
|
|
bash "$SCRIPT_DIR/sync_memory_central_to_repo.sh"
|
|
;;
|
|
*)
|
|
echo "사용: bash scripts/sync_memory.sh {both|repo-to-central|central-to-repo}" >&2
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
echo "✅ sync 완료. git status로 반영 확인."
|