Skip to content

Use Claude Code, Codex, VSCode, Pi, and OpenCode (and 6 other harnesses) for free (1.3B+ free tokens) from your terminal, app, IDE, or phone, and now from the browser with native browser sessions (multi-harness + multi-model) like OpenClaw (voice supported + ToS friendly)

Python

ci: run ruff format and auto-commit instead of format check

Cursor Agentebdfdbb6c983
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 9c2d22a5..f5299baf 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -9,6 +9,8 @@ on:
jobs:
ci:
runs-on: ubuntu-latest
+ permissions:
+ contents: write
steps:
- uses: actions/checkout@v4
@@ -29,5 +31,12 @@ jobs:
- name: Type check
run: uv run ty check
- - name: Check formatting
- run: uv run ruff format --check
+ - name: Format
+ run: uv run ruff format
+
+ - name: Commit and push formatting changes
+ run: |
+ git config user.name "github-actions[bot]"
+ git config user.email "github-actions[bot]@users.noreply.github.com"
+ git add -A
+ git diff --staged --quiet || (git commit -m "style: apply ruff format" && git push)