From 3675cab38553cd37a3c818808a3f51d48f0e4818 Mon Sep 17 00:00:00 2001 From: Thore Cimbal Date: Sun, 9 Aug 2026 12:00:00 +0000 Subject: [PATCH] ci: stamp the widget build with its version Without VITE_APP_VERSION the bundle calls itself dev - in developer settings and in every error message. Someone reporting a call problem then cannot say which build they were on. Set to the package version plus the short commit: the first says what was published, the second what was actually built. Between two publishes only the latter changes, and then it is the only thing that tells two builds apart. Closes axion1337.chat/threadnet-call#3 --- .gitlab-ci.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d7685287..4eb79335 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -53,6 +53,17 @@ build_embedded: before_script: - corepack enable script: + # Ohne VITE_APP_VERSION meldet sich das Widget als "dev" - im Entwicklermodus + # und in jeder Fehlermeldung. Wer einen Call-Fehler schildert, kann dann nicht + # sagen, welcher Stand lief (threadnet-call#3). + # + # Paketversion UND Commit: die erste sagt, was veroeffentlicht wurde, die + # zweite, was genau gebaut wurde. Zwischen zwei Publishes aendert sich nur die + # zweite - und genau dann ist sie die einzige Unterscheidung. + - | + VER=$(node -p "require('./embedded/web/package.json').version") + export VITE_APP_VERSION="${VER}+${CI_COMMIT_SHORT_SHA}" + echo "VITE_APP_VERSION=$VITE_APP_VERSION" - pnpm install --frozen-lockfile # baut mit der media_quality-Konfiguration aus vite-embedded.config.ts # (1440p-Defaults, h264 - siehe docs/axion1337-fork.md)