Skip to content

Commit cf4d18e

Browse files
committed
Fetch tags manually in publish workflow
`fetch-tags: true` in the checkout action does not work as expected and causes an error: Error: fatal: Cannot fetch both 2704e6e and refs/tags/v20241203 to refs/tags/v20241203 The issue is described in actions/checkout#1467 We will just fetch the tags manually
1 parent 2704e6e commit cf4d18e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Diff for: .github/workflows/reusable-docker-publish.yml

+5-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,11 @@ jobs:
2222
steps:
2323
- name: Checkout
2424
uses: actions/checkout@v4
25-
with:
26-
fetch-tags: true
25+
26+
- name: Fetch tags
27+
# Needed because of actions/checkout#1467
28+
run: |
29+
git fetch --tags --force
2730
2831
- name: Set up Docker Buildx
2932
uses: docker/setup-buildx-action@v3

0 commit comments

Comments
 (0)