opencode/script/format.ts
Dax Raad 26ebf85b0e
Some checks are pending
deploy / deploy (push) Waiting to run
format / format (push) Waiting to run
snapshot / publish (push) Waiting to run
ci: format
2025-09-27 02:22:03 -04:00

13 lines
385 B
TypeScript
Executable file

#!/usr/bin/env bun
import { $ } from "bun"
await $`bun run prettier --ignore-unknown --write`
if (process.env["CI"] && (await $`git status --porcelain`.text())) {
await $`git config --local user.email "action@github.com"`
await $`git config --local user.name "GitHub Action"`
await $`git add -A`
await $`git commit -m "chore: format code"`
await $`git push --no-verify`
}