The open source coding agent.
TypeScript
ci: fix fmt
Aiden Clined8401e193725
diff --git a/.github/workflows/format.yml b/.github/workflows/format.ymlindex 58fa8fca522..f2c783d6548 100644--- a/.github/workflows/format.yml+++ b/.github/workflows/format.yml@@ -18,6 +18,8 @@ jobs:uses: actions/checkout@v4with:token: ${{ secrets.GITHUB_TOKEN }}+ repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }}+ ref: ${{ github.event.pull_request.head.sha || github.sha }}- name: Setup Bunuses: ./.github/actions/setup-bun@@ -27,5 +29,3 @@ jobs:./script/format.tsenv:CI: true- GITHUB_HEAD_REF: ${{ github.head_ref }}- GITHUB_REF_NAME: ${{ github.ref_name }}diff --git a/script/format.ts b/script/format.tsindex aa0e82534ec..f5a54a57fcb 100755--- a/script/format.ts+++ b/script/format.ts@@ -5,10 +5,9 @@ import { $ } from "bun"await $`bun run prettier --ignore-unknown --write .`if (process.env["CI"] && (await $`git status --porcelain`.text())) {- const branch = process.env["GITHUB_HEAD_REF"] || process.env["GITHUB_REF_NAME"]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 origin HEAD:${branch} --no-verify`+ await $`git push --no-verify`}