Skip to content

Commit 217049f

Browse files
ovironclaude
andcommitted
fix(ci): unshallow byedpi submodule so describe yields the full core version
The metadata step fetched submodule tags, but the submodule is a shallow checkout, so git describe could not count commits back to the nearest tag and fell back to a bare short SHA (v0.1.1 shipped core.version "gba53229"). Unshallow the submodule before describe; reproduced the shallow condition locally and verified it now yields v0.17.3-38-gba53229. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 43e218f commit 217049f

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

‎.github/workflows/release.yml‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,12 @@ jobs:
5858
5959
- name: Write metadata.json (bundled core version + bridgeABI)
6060
run: |
61-
# Submodule is checked out without tags; fetch them so describe works,
62-
# fall back to a short SHA so the release never hard-fails.
63-
git -C src/main/cpp/byedpi fetch --tags --force origin >/dev/null 2>&1 || true
61+
# Submodule is a shallow checkout: describe needs both the tags AND the
62+
# history back to the nearest tag to count commits, so unshallow it.
63+
# Fall back to a plain tag fetch (complete clones reject --unshallow),
64+
# then to a short SHA so the release never hard-fails.
65+
git -C src/main/cpp/byedpi fetch --tags --force --unshallow origin >/dev/null 2>&1 \
66+
|| git -C src/main/cpp/byedpi fetch --tags --force origin >/dev/null 2>&1 || true
6467
CORE=$(git -C src/main/cpp/byedpi describe --tags --long 2>/dev/null \
6568
|| echo "g$(git -C src/main/cpp/byedpi rev-parse --short HEAD)")
6669
ABI=$(grep -oE 'EXPECTED_BRIDGE_ABI: Int = [0-9]+' \

0 commit comments

Comments
 (0)