Skip to content
This repository was archived by the owner on May 17, 2024. It is now read-only.

Commit 986c861

Browse files
authored
Merge pull request #815 from datafold/fix/formatter-github-action
Fix github action that doesn't work with forked branches
2 parents db7d864 + 280b7c5 commit 986c861

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

.github/workflows/formatter.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,23 @@ jobs:
1010
name: runner / ruff
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v3
13+
- name: Checkout PR head
14+
uses: actions/checkout@v3
15+
if: github.event_name == 'pull_request'
16+
with:
17+
repository: ${{ github.event.pull_request.head.repo.full_name }}
18+
ref: ${{ github.event.pull_request.head.ref }}
19+
20+
- name: Checkout Repo
21+
uses: actions/checkout@v3
22+
if: github.event_name == 'workflow_dispatch'
23+
1424
- name: Check files using the ruff formatter
1525
uses: chartboost/ruff-action@v1
1626
id: ruff_formatter
1727
with:
1828
args: format
29+
1930
- name: Auto commit ruff formatting
2031
uses: stefanzweifel/git-auto-commit-action@v5
2132
with:

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy