Commit 31742ae
fix: checkout PR branch in lint workflow instead of base branch
The lint.yml workflow uses pull_request_target trigger, which causes
actions/checkout to check out the base branch (main) by default.
This means rubocop runs against main's code, not the PR's changes.
Add ref parameter to checkout the PR's head branch, with fallback to
github.ref for workflow_dispatch and merge_group triggers.
Co-authored-by: ahpook <56753+ahpook@users.noreply.github.com>
Agent-Logs-Url: https://github.com/github/explore/sessions/f08905db-e076-48a4-8c19-6b4acc2c537c1 parent 188bdef commit 31742ae
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
| |||
0 commit comments