From c1f182c3d7d9dea490fe6eb37f235b343a2aaed6 Mon Sep 17 00:00:00 2001 From: "GHA: Update Upstream From Fork" Date: Mon, 11 Mar 2024 16:45:35 -0500 Subject: [PATCH] Move git fetch --all earlier --- .github/workflows/cherry-pick-from-branch.sh | 3 ++- .github/workflows/update_upstream_from_fork.yml | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cherry-pick-from-branch.sh b/.github/workflows/cherry-pick-from-branch.sh index 9744fc5..76a23cb 100755 --- a/.github/workflows/cherry-pick-from-branch.sh +++ b/.github/workflows/cherry-pick-from-branch.sh @@ -5,6 +5,7 @@ # In a repo # $DEST_REPO/$DEST_BRANCH is defined, readable, and writeable # $BEFORE_SHA..$LAST_SHA must define a sequence of commits +# fetch all has just been run DEST_REMOTE=$1 DEST_BRANCH=$2 @@ -21,7 +22,7 @@ SKIP_COMMIT_STRING="DO NOT SYNC" # TODO Maybe don't need these? I think the identity of the PAT is overriding them anyway # git config --global user.email "noreply@anza.xyz" # git config --global user.name "GHA: Update Upstream From Fork" #TODO better name -git fetch --all +# git fetch --all echo "-------------------------" echo "git log --oneline remotes/$DEST_REMOTE/$DEST_BRANCH:" git log --oneline "remotes/$DEST_REMOTE/$DEST_BRANCH" diff --git a/.github/workflows/update_upstream_from_fork.yml b/.github/workflows/update_upstream_from_fork.yml index 0f4488f..4fa2e3b 100644 --- a/.github/workflows/update_upstream_from_fork.yml +++ b/.github/workflows/update_upstream_from_fork.yml @@ -51,6 +51,7 @@ jobs: shell: bash - name: show remotes and branches run: | + git fetch --all git remote --verbose git branch --all git log --oneline "origin/$BRANCH_REF"