@@ -196,6 +196,16 @@ jobs:
196196 echo "OK: $bin"
197197 done
198198
199+ # The native codex CLI must ship as a sibling of codex-acp, or the
200+ # app-server harness silently falls back to codex-acp in production.
201+ for f in codex rg; do
202+ if [[ ! -f "$RESOURCES/app.asar.unpacked/.vite/build/codex-acp/$f" ]]; then
203+ echo "FAIL: codex-acp/$f missing in bundled binaries"
204+ exit 1
205+ fi
206+ echo "OK: codex-acp/$f"
207+ done
208+
199209 - name : Install Playwright
200210 run : pnpm --filter code exec playwright install
201211
@@ -223,6 +233,21 @@ jobs:
223233 apps/code/out/*-mac.zip \
224234 apps/code/out/*.blockmap
225235
236+ # Hash the same files uploaded above; finalize-release turns these into
237+ # the download tables in the release notes.
238+ - name : Compute artifact checksums
239+ env :
240+ MATRIX_ARCH : ${{ matrix.arch }}
241+ working-directory : apps/code/out
242+ run : shasum -a 256 *.dmg *-mac.zip *.blockmap > "checksums-macos-$MATRIX_ARCH.txt"
243+
244+ - name : Upload checksums artifact
245+ uses : actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
246+ with :
247+ name : checksums-macos-${{ matrix.arch }}
248+ path : apps/code/out/checksums-macos-${{ matrix.arch }}.txt
249+ retention-days : 1
250+
226251 - name : Upload mac manifest artifact
227252 uses : actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
228253 with :
@@ -332,6 +357,20 @@ jobs:
332357 $files = $items | Select-Object -ExpandProperty FullName
333358 gh release upload "v$env:APP_VERSION" --repo PostHog/code --clobber @files
334359
360+ # Hash the same files uploaded above (minus latest.yml); finalize-release
361+ # turns these into the download tables in the release notes.
362+ - name : Compute artifact checksums
363+ shell : bash
364+ working-directory : apps/code/out
365+ run : sha256sum *.exe *.blockmap > checksums-windows-x64.txt
366+
367+ - name : Upload checksums artifact
368+ uses : actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
369+ with :
370+ name : checksums-windows-x64
371+ path : apps/code/out/checksums-windows-x64.txt
372+ retention-days : 1
373+
335374 publish-linux :
336375 needs : [prepare-release]
337376 strategy :
@@ -444,6 +483,21 @@ jobs:
444483 apps/code/out/*.deb \
445484 apps/code/out/*.rpm
446485
486+ # Hash the same files uploaded above; finalize-release turns these into
487+ # the download tables in the release notes.
488+ - name : Compute artifact checksums
489+ env :
490+ MATRIX_ARCH : ${{ matrix.arch }}
491+ working-directory : apps/code/out
492+ run : sha256sum *.AppImage *.deb *.rpm > "checksums-linux-$MATRIX_ARCH.txt"
493+
494+ - name : Upload checksums artifact
495+ uses : actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
496+ with :
497+ name : checksums-linux-${{ matrix.arch }}
498+ path : apps/code/out/checksums-linux-${{ matrix.arch }}.txt
499+ retention-days : 1
500+
447501 finalize-release :
448502 needs : [publish-macos, publish-windows, publish-linux]
449503 # Publish only when every platform built successfully. Without an `if:` override
@@ -471,6 +525,7 @@ jobs:
471525 with :
472526 sparse-checkout : |
473527 apps/code/scripts/merge-mac-manifests.mjs
528+ apps/code/scripts/generate-release-download-tables.mjs
474529 sparse-checkout-cone-mode : false
475530
476531 - name : Setup Node.js
@@ -508,10 +563,19 @@ jobs:
508563 run : |
509564 gh release upload "v$APP_VERSION" --repo PostHog/code --clobber /tmp/latest-mac.yml
510565
566+ - name : Download checksum artifacts
567+ uses : actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
568+ with :
569+ pattern : checksums-*
570+ merge-multiple : true
571+ path : /tmp/checksums
572+
511573 - name : Publish GitHub release
512574 env :
513575 GH_TOKEN : ${{ steps.app-token.outputs.token }}
514576 APP_VERSION : ${{ steps.version.outputs.version }}
515577 run : |
516578 gh api repos/PostHog/code/releases/generate-notes -f tag_name="v$APP_VERSION" --jq '.body' > /tmp/release-notes.md
579+ printf '\n' >> /tmp/release-notes.md
580+ node apps/code/scripts/generate-release-download-tables.mjs "$APP_VERSION" /tmp/checksums >> /tmp/release-notes.md
517581 gh release edit "v$APP_VERSION" --repo PostHog/code --draft=false --notes-file /tmp/release-notes.md
0 commit comments