Fresh start - excluded large ROM JSON files
This commit is contained in:
20
scripts/setup-backup-task.ps1
Normal file
20
scripts/setup-backup-task.ps1
Normal file
@@ -0,0 +1,20 @@
|
||||
# PowerShell script to create a Windows Scheduled Task for memory backup
|
||||
# Run this as Administrator
|
||||
|
||||
$taskName = "OpenClaw Memory Backup"
|
||||
$description = "Backup MEMORY.md to Supermemory every 6 hours"
|
||||
|
||||
# Task action - run the Python script
|
||||
$action = New-ScheduledTaskAction -Execute "python" -Argument "scripts\backup-memory.py" -WorkingDirectory "$env:USERPROFILE\.openclaw\workspace"
|
||||
|
||||
# Trigger - every 6 hours
|
||||
$trigger = New-ScheduledTaskTrigger -Daily -At "00:00" -RepetitionInterval (New-TimeSpan -Hours 6) -RepetitionDuration (New-TimeSpan -Days 1)
|
||||
|
||||
# Settings
|
||||
$settings = New-ScheduledTaskSettingsSet -AllowStartIfOnBatteries -DontStopIfGoingOnBatteries
|
||||
|
||||
# Register the task
|
||||
Register-ScheduledTask -TaskName $taskName -Action $action -Trigger $trigger -Settings $settings -Description $description -RunLevel Limited
|
||||
|
||||
Write-Host "[OK] Scheduled task '$taskName' created successfully!"
|
||||
Write-Host " Runs every 6 hours starting at midnight"
|
||||
Reference in New Issue
Block a user