From 77762b983e10112e1e5b1c319a78d7b4d3ee63ca Mon Sep 17 00:00:00 2001 From: hoelee Date: Mon, 6 Jul 2026 09:00:00 +0800 Subject: [PATCH] feat(shell-sync): add start_heartbeat() --- platform/shell-sync/sync.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/platform/shell-sync/sync.sh b/platform/shell-sync/sync.sh index f263ccc5..757879dc 100644 --- a/platform/shell-sync/sync.sh +++ b/platform/shell-sync/sync.sh @@ -327,3 +327,12 @@ sync_all() { [ "$failures" -eq 0 ] && [ "$notification_failures" -eq 0 ] } +start_heartbeat() { + echo "$(date +%s)" > "$HEARTBEAT_FILE" + while true; do + echo "$(date +%s)" > "$HEARTBEAT_FILE" + sleep 60 + done & + HEARTBEAT_PID=$! +} +