File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change 44jobs :
55 pre-commit :
66 runs-on : ubuntu-24.04
7+ if : github.event_name != 'push'
78 steps :
89 - uses : actions/checkout@v4
910 with :
1718 python3 -m pip install -r requirements.txt
1819 - name : Run pre-commit checks
1920 run : |
20- # For push events, compare with previous commit
21- if [ "${{ github.event_name }}" = "push" ]; then
22- pre-commit run --from-ref HEAD~1 --to-ref HEAD
23- else
24- # For PRs, compare with base branch
25- git fetch origin ${{ github.base_ref }}:${{ github.base_ref }}
26- pre-commit run --from-ref ${{ github.base_ref }} --to-ref HEAD
27- fi
21+ git fetch origin ${{ github.base_ref }}:${{ github.base_ref }}
22+ pre-commit run --from-ref ${{ github.base_ref }} --to-ref HEAD
2823 gcc-build :
2924 needs :
3025 - pre-commit
You can’t perform that action at this time.
0 commit comments