Skip to content

Commit

Permalink
Check out head_ref of source branch on PRs (#188)
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisfenner authored Sep 23, 2024
1 parent d1afe7b commit c655a73
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/render.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,18 @@ jobs:
echo OUTPUT_FILENAME="${filename}" >> "$GITHUB_OUTPUT"
echo output filename: ${filename}
# For pull requests, check out the head ref of the source branch.
- name: Checkout
if: inputs.workflow == 'pr'
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
fetch-depth: 0
fetch-tags: true
# For other workflows, check out the requested revision (which defaults to
# head of the default branch).
- name: Checkout
if: inputs.workflow != 'pr'
uses: actions/checkout@v4
with:
ref: ${{ inputs.revision }}
Expand Down

0 comments on commit c655a73

Please sign in to comment.