From 3e2be20614b2c5b2eaed7f486c43c8e6e584a5f2 Mon Sep 17 00:00:00 2001 From: Hamish Coleman Date: Sun, 31 Oct 2021 17:08:10 +0000 Subject: [PATCH] Try returning to the 'normal' command, after force pulling the correct repo data --- .github/workflows/tests.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6508c65..c5a479b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -507,13 +507,13 @@ jobs: # the annotated tag is visible in the "commit" action, but looks like a # lightweight tag in the "tag" action # - # So, instead of: - # TAGTYPE=$(git cat-file -t $GITHUB_REF) - # We try to build a workaround + # It appears that the repository that is checked out as part of a tag + # action does not have the correct tag object in it. As a work around, + # we do a force pull of the repo to get the correct tag details. - name: Get Tag Type run: | - git pull --tags --force - if git cat-file tag $GITHUB_REF; then TYPE=tag; else TYPE=commit; fi + git pull --tags --force origin HEAD + TYPE=$(git cat-file -t $GITHUB_REF) echo "::set-output name=TAGTYPE::$TYPE" echo ================Debug