Skip to content

Commit 35e202c

Browse files
Fix firmware filenames to always use VERSION instead of commit hash
Both nRF52 and ESP32 builds now use check-version-tag.outputs.version for firmware filenames, ensuring consistent version naming regardless of whether VERSION file changed in the current commit.
1 parent 7832dcb commit 35e202c

1 file changed

Lines changed: 4 additions & 12 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -313,12 +313,8 @@ jobs:
313313
run: |
314314
cd /zephyr_workspace
315315
316-
# Use version if VERSION file changed, otherwise use commit SHA
317-
if [ "${{ needs.check-changes.outputs.version_changed }}" = "true" ]; then
318-
FILENAME_VERSION=$(cat VERSION | tr -d '[:space:]')
319-
else
320-
FILENAME_VERSION=$(echo "${{ github.sha }}" | cut -c1-7)
321-
fi
316+
# Always use version from check-version-tag
317+
FILENAME_VERSION="${{ needs.check-version-tag.outputs.version }}"
322318
323319
# Clean up any old firmware files from cached workspace
324320
rm -f mp_usb_*.uf2 mp_usb_*.zip mp_usb_*.hex
@@ -391,12 +387,8 @@ jobs:
391387
run: |
392388
mkdir -p artifacts
393389
394-
# Use version if VERSION file changed, otherwise use commit SHA
395-
if [ "${{ needs.check-changes.outputs.version_changed }}" = "true" ]; then
396-
FILENAME_VERSION=$(cat VERSION | tr -d '[:space:]')
397-
else
398-
FILENAME_VERSION=$(echo "${{ github.sha }}" | cut -c1-7)
399-
fi
390+
# Always use version from check-version-tag
391+
FILENAME_VERSION="${{ needs.check-version-tag.outputs.version }}"
400392
401393
# Copy app binary only (preserves NVS/BLE bonds when flashed at 0x10000)
402394
cp esp/build/mouthpad_usb.bin artifacts/mp_usb_${FILENAME_VERSION}_${{ matrix.board.name }}.bin

0 commit comments

Comments
 (0)