From d15c41851df12d22eb90b0c327cb3372d28e5932 Mon Sep 17 00:00:00 2001 From: Bharat Date: Thu, 30 Jul 2026 08:59:17 +0100 Subject: [PATCH] PLAT-2003/ci: run pre-commit in CI This repo has a .pre-commit-config.yaml, including the uv-lock hook added in the PLAT-2003 sweep, but nothing runs pre-commit in CI. So the hooks only fire for developers who have pre-commit installed locally, and a PR that introduces lock drift or a formatting regression goes green. Add the same Style workflow the other repos use, on the consolidated two-inc/actions-public/pre-commit action. The older two-inc/pre-commit-action sets an unauthenticated PIP_EXTRA_INDEX_URL, which makes pip prompt for credentials and die with EOFError on a cold hook cache. --- .github/workflows/style.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/style.yaml diff --git a/.github/workflows/style.yaml b/.github/workflows/style.yaml new file mode 100644 index 0000000..464b258 --- /dev/null +++ b/.github/workflows/style.yaml @@ -0,0 +1,21 @@ +name: Style + +on: + pull_request: + types: [opened, synchronize, reopened] + +concurrency: + group: pre-commit-${{ github.ref_name }} + cancel-in-progress: true + +jobs: + pre-commit: + runs-on: ${{ vars.RUNNER_STANDARD }} + timeout-minutes: 20 + permissions: + contents: read + pull-requests: write + steps: + - uses: two-inc/actions-public/pre-commit@main + with: + python-version: "3.10"