MCPcopy Create free account
hub / github.com/ByBrawe/opencode-loop / nextDueDelay

Function nextDueDelay

src/index.js:904–910  ·  view source on GitHub ↗
(state)

Source from the content-addressed store, hash-verified

902 await fs.writeFile(path.join(checkpointDir, `${prefix}.patch`), `${diff.stdout}\n${staged.stdout}`)
903 if (job.gitCheckpoint) {
904 await runProcess("git", ["add", "-A"], directory, 120_000)
905 await runProcess("git", ["commit", "-m", `chore: opencode loop checkpoint ${timestamp}`], directory, 120_000)
906 }
907 await toast(client, `Loop checkpoint saved: ${prefix}`, "success")
908}
909
910function updateSessionStatusFromEvent(event) {
911 const sessionID = event?.properties?.sessionID
912 if (typeof sessionID !== "string") return undefined
913 if (event?.type === "session.idle") {

Callers 2

startWatchdogFunction · 0.85
scheduleDueWorkFunction · 0.85

Calls 2

nowFunction · 0.85
jobDueAtFunction · 0.85

Tested by

no test coverage detected