-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathautocommit-snippet.yml
More file actions
24 lines (19 loc) · 944 Bytes
/
Copy pathautocommit-snippet.yml
File metadata and controls
24 lines (19 loc) · 944 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
- name: Run ruff on changed files
if: steps.changed-py-files.outputs.any_changed == 'true'
run: |
uv run ruff check ${{ steps.changed-py-files.outputs.all_changed_files }}
uv run ruff format ${{ steps.changed-py-files.outputs.all_changed_files }}
# - name: Commit linter and formatter changes
# run: |
# echo "Committing linter and formatter changes using our pyproject agreed rules"
# git config user.name "github-actions[bot]"
# git config user.email "github-actions[bot]@users.noreply.github.com"
#
# git add .
# git commit -m "LINTER BOT: lint and format in CI [skip ci]" || echo "No changes to commit"
#
# if [ "${{ github.event_name }}" = "pull_request" ]; then
# git push origin HEAD:${{ github.head_ref }}
# else
# git push origin ${{ github.ref_name }}
# fi