Skip to content

Commit 8748115

Browse files
committed
fix: Attempt to workaround actions/checkout#1467
Currently, the checkout GitHub Action failed to check out when both `fetch-depth` and `fetch-tags` are specified during a tag push event(actions/checkout#1467). This patch workarounds the issue by manually do the tag fetch afterwards. Refer-to: Can't fetch with `fetch-tags` when triggered by tag · Issue #1467 · actions/checkout <actions/checkout#1467> Refer-to: Switch back to an improved manual tag fetching method · wxFormBuilder/wxFormBuilder@459563b <wxFormBuilder/wxFormBuilder@459563be8> Signed-off-by: 林博仁(Buo-ren, Lin) <[email protected]>
1 parent ef181b5 commit 8748115

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

Diff for: .github/workflows/release.yml

+11-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,17 @@ jobs:
2626
fetch-depth: 100
2727

2828
# Fetch tags as well to generate detailed changes between two releases
29-
fetch-tags: true
29+
# WORKAROUND: Adding this option triggers actions/checkout#1467
30+
#fetch-tags: true
31+
32+
- name: >-
33+
WORKAROUND: Fetch tags that points to the revisions
34+
checked-out(actions/checkout#1467)
35+
run: |-
36+
git fetch \
37+
--prune \
38+
--depth=1 \
39+
--no-recurse-submodules
3040
3141
- name: Determine the project identifier
3242
run: printf "project_id=${GITHUB_REPOSITORY##*/}\\n" >> $GITHUB_ENV

0 commit comments

Comments
 (0)