chore: CI: fix workflow change breaking unrebased PRs (#4441)

This commit is contained in:
Sebastian Ullrich 2024-06-13 11:56:31 +02:00 committed by GitHub
parent bd3b466f2f
commit 37f8b0390d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -280,12 +280,6 @@ jobs:
CXX: c++
MACOSX_DEPLOYMENT_TARGET: 10.15
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: true
# the default is to use a virtual merge commit between the PR and master: just use the PR
ref: ${{ github.event.pull_request.head.sha }}
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@main
if: runner.os == 'Linux' && !matrix.cmultilib
@ -311,6 +305,18 @@ jobs:
sudo apt-get update
sudo apt-get install -y gcc-multilib g++-multilib ccache
if: matrix.cmultilib
- name: Checkout
uses: actions/checkout@v4
with:
# the default is to use a virtual merge commit between the PR and master: just use the PR
ref: ${{ github.event.pull_request.head.sha }}
# Do check out some CI-relevant files from virtual merge commit to accommodate CI changes on
# master (as the workflow files themselves are always taken from the merge)
- name: CI Merge Checkout
run: |
git fetch origin ${{ github.event.pull_request.merge_commit_sha }}
git checkout FETCH_HEAD flake.nix flake.lock
if: github.event_name == 'pull_request'
- name: Cache
uses: actions/cache@v3
with: