diff --git a/cloud/scripts/package.json b/cloud/scripts/package.json index 03e8a11a..0b8a5c5f 100644 --- a/cloud/scripts/package.json +++ b/cloud/scripts/package.json @@ -5,8 +5,9 @@ "private": true, "type": "module", "scripts": { - "start": "tsx", - "shell": "sst shell" + "shell": "sst shell -- bun tsx", + "shell-dev": "sst shell --stage dev -- bun tsx", + "shell-prod": "sst shell --stage production -- bun tsx" }, "dependencies": { "@opencode/cloud-core": "workspace:*", diff --git a/cloud/scripts/src/backfill-usage-provider.ts b/cloud/scripts/src/backfill-usage-provider.ts new file mode 100644 index 00000000..553dcb47 --- /dev/null +++ b/cloud/scripts/src/backfill-usage-provider.ts @@ -0,0 +1,10 @@ +import { Database, eq } from "@opencode/cloud-core/drizzle/index.js" +import { UsageTable } from "@opencode/cloud-core/schema/billing.sql.js" + +await Database.use(async (tx) => { + await tx + .update(UsageTable) + .set({ model: "grok-code" }) + .where(eq(UsageTable.model, "x-ai/grok-code-fast-1")) + .limit(90000) +}) diff --git a/cloud/scripts/src/placeholder.ts b/cloud/scripts/src/placeholder.ts deleted file mode 100644 index ff7bd09c..00000000 --- a/cloud/scripts/src/placeholder.ts +++ /dev/null @@ -1 +0,0 @@ -// placeholder