Skip to content

Commit

Permalink
fix: ensure HEAD ref for git push
Browse files Browse the repository at this point in the history
  • Loading branch information
dwinston committed Jan 17, 2024
1 parent f893c55 commit 9c5c1f1
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
name: Lint-check + Style-normalize Python files

on:
push:
branches: [ main ]
paths:
- '.github/workflows/lint.yml'
- '**.py'
pull_request:
paths:
- '.github/workflows/lint.yml'
Expand All @@ -23,6 +18,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: '3.10'
ref: ${{ github.event.pull_request.head.ref }}
- name: Lint with flake8 and Reformat with black
run: |
make init-lint-and-black
Expand All @@ -32,6 +28,5 @@ jobs:
run: |
git config user.name github-actions
git config user.email [email protected]
git config push.autoSetupRemote true
if git status --short | grep -q '\.py$'; then git add '*.py' && git commit -m "style: reformat" && git push; fi

0 comments on commit 9c5c1f1

Please sign in to comment.