diff --git a/.forgejo/workflows/build-arm64.yml b/.forgejo/workflows/build-arm64.yml index 99719aae..9b657bb5 100644 --- a/.forgejo/workflows/build-arm64.yml +++ b/.forgejo/workflows/build-arm64.yml @@ -41,6 +41,14 @@ jobs: with: fetch-depth: 0 + - name: Build main as it is now + # A scheduled run checks out the commit its schedule was registered + # at, which can be behind main (see build.yml). + if: github.event_name == 'schedule' + run: | + git fetch --no-tags origin main + git checkout -B main FETCH_HEAD + - name: Point downloads at our mirrors # As build.yml. run: | diff --git a/.forgejo/workflows/build.yml b/.forgejo/workflows/build.yml index 1f9cfef3..fd8a5a57 100644 --- a/.forgejo/workflows/build.yml +++ b/.forgejo/workflows/build.yml @@ -59,6 +59,11 @@ jobs: run: | git config user.name "forgejo-actions" git config user.email "actions@forge.quinefoundation.com" + # A scheduled run checks out the commit its schedule was registered + # at, the last push without [skip ci], which can be behind main: + # merge onto main as it is now, or the push below is rejected. + git fetch --no-tags origin main + git checkout -B main FETCH_HEAD # Our pull mirror of github.com/ublue-os/aurora, synced hourly. git fetch --no-tags "$MIRRORS/mirror-ublue-os-aurora.git" main before=$(git rev-parse HEAD)