Skip to content

Commit f203db4

Browse files
committed
feat: update GitHub Actions workflow for formatting and dependency versions
1 parent 5cedae1 commit f203db4

1 file changed

Lines changed: 16 additions & 5 deletions

File tree

.github/workflows/test.yml

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,32 @@ jobs:
1313
uv-test:
1414
name: python
1515
runs-on: ubuntu-latest
16+
permissions:
17+
contents: write
1618

1719
steps:
18-
- uses: actions/checkout@v5
19-
- uses: actions/setup-python@v6
20+
- uses: actions/checkout@v4
21+
with:
22+
ref: ${{ github.head_ref }}
23+
24+
- uses: actions/setup-python@v5
2025
with:
2126
python-version: '3.11'
2227

2328
- name: Install uv
24-
uses: astral-sh/setup-uv@v7
29+
uses: astral-sh/setup-uv@v5
2530

2631
- name: Install the project
2732
run: make install
2833

29-
- name: Check formatting with black
30-
run: uv run black --check .
34+
- name: Format with black
35+
run: uv run black .
36+
37+
- name: Commit formatted code
38+
uses: stefanzweifel/git-auto-commit-action@v5
39+
with:
40+
commit_message: 'style: auto-format with black'
41+
file_pattern: '*.py'
3142

3243
- name: Run tests
3344
run: make test

0 commit comments

Comments
 (0)