Skip to content

Commit 6fe0dff

Browse files
authored
Explicitly checkout to PR (merge) commit (#565)
* allow commit * allow commit * update * update * update * update * Update build_pr_documentation.yml --------- Co-authored-by: ydshieh <[email protected]>
1 parent 7ef600c commit 6fe0dff

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

.github/workflows/build_pr_documentation.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,12 @@ jobs:
7979
repository: '${{ inputs.repo_owner }}/${{ inputs.package }}'
8080
path: ${{ inputs.package }}
8181

82+
- name: Checkout to the correct commit
83+
working-directory: ${{ inputs.package }}
84+
run: |
85+
git fetch https://github.com/${{ inputs.repo_owner }}/${{ inputs.package }}.git refs/pull/${{ inputs.pr_number }}/merge:refs/remotes/pull/${{ inputs.pr_number }}/merge
86+
git checkout refs/remotes/pull/${{ inputs.pr_number }}/merge
87+
8288
- uses: actions/setup-node@v4
8389
with:
8490
node-version: '20'

0 commit comments

Comments
 (0)