From a405513d84b2dfd98d35c6855e37e245bf425743 Mon Sep 17 00:00:00 2001 From: Kaj Schittecat Date: Sat, 13 Jun 2026 16:08:10 +0200 Subject: [PATCH] flasher: show current release version + notes (pipeline-driven) The esp-web-tools manifest carried a frozen version:beta_1 while the rolling /latest/ bins moved on, so the web flasher always said beta_1. Fix: - scripts/build/gen-flasher-meta.py emits version.json (tag + notes) + per-release manifests (version=tag) into /latest/; release.sh + the CI workflow run it, so the metadata rolls with every release. - the site points the install buttons at the VPS manifests and renders a live 'What's new in ' block from version.json. - drop the frozen static site manifests. Co-Authored-By: Claude Opus 4.8 (1M context) --- .github/workflows/release.yml | 6 ++++ deploy/site/index.html | 24 ++++++++++++-- deploy/site/manifest-heltec-v4-tft.json | 13 -------- deploy/site/manifest-tdeck.json | 13 -------- release-notes/beta_2.txt | 4 +++ scripts/build/gen-flasher-meta.py | 44 +++++++++++++++++++++++++ scripts/release.sh | 5 +++ 7 files changed, 81 insertions(+), 28 deletions(-) delete mode 100644 deploy/site/manifest-heltec-v4-tft.json delete mode 100644 deploy/site/manifest-tdeck.json create mode 100644 release-notes/beta_2.txt create mode 100644 scripts/build/gen-flasher-meta.py diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5643f52..509b57f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -87,6 +87,11 @@ jobs: done ls -la dist + - name: Web-flasher metadata (version.json + manifests, roll with release) + env: + TAG: ${{ steps.v.outputs.tag }} + run: python3 scripts/build/gen-flasher-meta.py "$TAG" dist "release-notes/$TAG.txt" + - name: Create / update the GitHub Release env: GH_TOKEN: ${{ github.token }} @@ -117,6 +122,7 @@ jobs: scp -i ~/.ssh/id_deploy "dist/$n.bin" "dist/$n-merged.bin" "$VPS:$REL/" scp -i ~/.ssh/id_deploy "dist/$n-merged.bin" "dist/$n.bin" "$VPS:$VPS_PATH/latest/" done + scp -i ~/.ssh/id_deploy dist/version.json dist/manifest-tdeck.json dist/manifest-heltec-v4-tft.json "$VPS:$VPS_PATH/latest/" $SSH "$VPS" "cd '$VPS_PATH/releases/TOUCH' && python3 -c \"import os,json; b=sorted(d for d in os.listdir('.') if d.startswith('beta_') and os.path.isdir(d)); open('index.json','w').write(json.dumps([{'name':x,'type':'dir'} for x in b], indent=2))\"" rm -f ~/.ssh/id_deploy echo "Published $TAG to wadamesh.com" diff --git a/deploy/site/index.html b/deploy/site/index.html index 500ae57..5ab2a82 100644 --- a/deploy/site/index.html +++ b/deploy/site/index.html @@ -245,6 +245,10 @@

Standalone install

Plug the device in over USB and flash it right here. Works in Chrome or Edge on desktop.

+
1

Connect over USB

Plug your T-Deck or Heltec V4 into your computer with a data cable.

2

Pick your board & install

Hit Install below, choose the serial port, and let it flash. It does a clean full install.

@@ -252,9 +256,9 @@

Heltec V4 + TFT

ESP32-S3 with CHSC6x touch.

-
+

LilyGo T-Deck / Plus

ESP32-S3 keyboard handheld.

-
+
Your browser can't flash here — use Chrome or Edge on a desktop.

T-Deck not detected? Hold the trackball while tapping reset to force download mode.

@@ -379,6 +383,22 @@ We use no tracking, analytics, or advertising cookies. Our CDN and security prov try { if (!localStorage.getItem('wm-cookie-ack')) cbar.classList.add('show'); } catch(_) {} document.getElementById('cookieok').addEventListener('click', () => { cbar.classList.remove('show'); try { localStorage.setItem('wm-cookie-ack','1'); } catch(_) {} }); + // Live release version + "what's new" — read from the firmware host so the + // flasher always reflects the current build (the release pipeline updates + // version.json; no site redeploy needed per release). + fetch('https://firmware.wadamesh.com/latest/version.json', {cache:'no-store'}) + .then(r => r.ok ? r.json() : null) + .then(v => { + if (!v || !v.tag) return; + document.querySelectorAll('[data-wn-tag]').forEach(e => e.textContent = v.tag); + const notes = Array.isArray(v.notes) ? v.notes : []; + document.querySelectorAll('[data-wn-notes]').forEach(ul => { + ul.innerHTML = ''; + notes.forEach(n => { const li = document.createElement('li'); li.textContent = n; ul.appendChild(li); }); + }); + if (notes.length) document.querySelectorAll('[data-whatsnew]').forEach(b => b.hidden = false); + }).catch(()=>{}); +