From 3c6741b11cf78451bbad8857e255b32e48b2cfd1 Mon Sep 17 00:00:00 2001 From: Amir Gonnen Date: Tue, 15 Sep 2020 13:19:56 +0300 Subject: [PATCH] Update build_micropython.yml (#1794) Fetch both head and merge commits of "pull" refs. This would allow the CI script to first try checkout the merge commit (which is `github.sha` on PR) and only if that fails, default to checking out the PR head. --- .github/workflows/build_micropython.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_micropython.yml b/.github/workflows/build_micropython.yml index 31487c7b64..2608abde4e 100644 --- a/.github/workflows/build_micropython.yml +++ b/.github/workflows/build_micropython.yml @@ -25,7 +25,7 @@ jobs: working-directory: ./lib/lv_bindings/lvgl run: | git fetch --force ${{ github.event.repository.git_url }} "+refs/heads/*:refs/remotes/origin/*" - git fetch --force ${{ github.event.repository.git_url }} "+refs/pull/*/head:refs/remotes/origin/pr/*" + git fetch --force ${{ github.event.repository.git_url }} "+refs/pull/*:refs/remotes/origin/pr/*" git checkout ${{ github.sha }} || git checkout ${{ github.event.pull_request.head.sha }} git submodule update --init --recursive - name: Build mpy-cross