name: autofix.ci permissions: contents: read on: workflow_call: workflow_dispatch: pull_request: merge_group: push: branches: ["main"] env: BUN_VERSION: "1.2.11" LLVM_VERSION: "19.1.7" LLVM_VERSION_MAJOR: "19" jobs: autofix: name: Format runs-on: ubuntu-latest concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true steps: - name: Checkout uses: actions/checkout@v4 - name: Configure Git run: | git config --global core.autocrlf true git config --global core.ignorecase true git config --global core.precomposeUnicode true - name: Setup Bun uses: ./.github/actions/setup-bun with: bun-version: ${{ env.BUN_VERSION }} - name: Setup Dependencies run: | bun install - name: Install LLVM run: | curl -fsSL https://apt.llvm.org/llvm.sh | sudo bash -s -- ${{ env.LLVM_VERSION_MAJOR }} all - name: Setup Zig uses: mlugg/setup-zig@v1 with: version: 0.14.0 - name: Zig Format run: | bun scripts/zig-remove-unreferenced-top-level-decls.ts src/ zig fmt src bun scripts/sortImports src zig fmt src - name: Prettier Format run: | bun run prettier - name: Clang Format run: | bun run clang-format - uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27