From 72db15e69709eb7edbd679a04e2399f50e2433b4 Mon Sep 17 00:00:00 2001 From: Angela Tran Date: Tue, 9 Jan 2024 18:34:30 +0000 Subject: [PATCH 1/2] refactor(ci): simplify tag-fetching during checkout --- .github/workflows/docker-publish.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 1e9ce084..9b812153 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -38,11 +38,8 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 - - - name: Get history and tags for SCM versioning to work - run: | - git fetch --prune --unshallow - git fetch --depth=1 origin +refs/tags/*:refs/tags/* + with: + fetch-tags: true - uses: actions/setup-python@v5 with: From 123b9794c17b629144e286a0a678ff895e63b63a Mon Sep 17 00:00:00 2001 From: Angela Tran Date: Tue, 9 Jan 2024 18:37:50 +0000 Subject: [PATCH 2/2] fix: add tag-fetching to release creation workflow --- .github/workflows/release.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 67bd762b..13c4d350 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,3 +1,5 @@ +name: Create GitHub release + on: push: tags: @@ -13,6 +15,8 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 + with: + fetch-tags: true - name: Release uses: softprops/action-gh-release@v1