mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-29 11:42:17 +00:00
10 lines
468 B
TypeScript
10 lines
468 B
TypeScript
import { R2Sql } from "@opencode/stats-core/r2-sql"
|
|
import { layer } from "@opencode/stats-core/runtime"
|
|
import { syncStats } from "@opencode/stats-core/stat-sync"
|
|
import { Effect, Layer } from "effect"
|
|
|
|
// Runs one sync pass in this process, for local use. Deployed stages run the
|
|
// same steps in the StatsSyncWorkflow.
|
|
await Effect.runPromise(
|
|
syncStats({ history: process.argv.includes("--history") }).pipe(Effect.provide(Layer.mergeAll(layer, R2Sql.layer))),
|
|
)
|