diff options
| author | Dax Raad <[email protected]> | 2025-09-09 23:47:47 -0400 |
|---|---|---|
| committer | Dax Raad <[email protected]> | 2025-09-09 23:47:47 -0400 |
| commit | e53fb7f8eda760b9d39479a2038720d54a434629 (patch) | |
| tree | 2cd58463253e72d0331bb88d2b9316f9bcd86997 /script | |
| parent | b05cbc910130ed9924f33ece3b5a70885f2f126d (diff) | |
| download | opencode-e53fb7f8eda760b9d39479a2038720d54a434629.tar.gz opencode-e53fb7f8eda760b9d39479a2038720d54a434629.zip | |
ci: format
Diffstat (limited to 'script')
| -rwxr-xr-x | script/format.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/script/format.ts b/script/format.ts new file mode 100755 index 000000000..d80820409 --- /dev/null +++ b/script/format.ts @@ -0,0 +1,13 @@ +#!/usr/bin/env bun + +import { $ } from "bun" + +await $`bun run prettier --ignore-unknown --write $(git ls-files)` + +if (process.env["CI"] && (await $`git status --porcelain`.text())) { + await $`git config --local user.email "[email protected]"` + await $`git config --local user.name "GitHub Action"` + await $`git add -A` + await $`git commit -m "chore: format code"` + await $`git push` +} |
