From 0c2fcfd745c533acba76b5675c31a86a35a94260 Mon Sep 17 00:00:00 2001 From: Russell Keith-Magee Date: Sat, 3 Aug 2024 15:48:56 +0800 Subject: [PATCH] Reference the SHA of the pull request HEAD in the checkout. --- .github/workflows/ci.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fc2017dc5d..632e11196a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,7 +9,12 @@ jobs: runs-on: ubuntu-latest if: contains(github.event.pull_request.labels.*.name, 'preview') steps: - - uses: actions/checkout@v4 + - name: Checkout + uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha }} + fetch-depth: 0 + - name: Set up Python uses: actions/setup-python@v5 with: