Cache bust plugin assets

This commit is contained in:
Mikei386
2026-06-23 07:00:26 +02:00
parent 068973ab9b
commit d7a62eb15e
6 changed files with 10 additions and 6 deletions
+2 -1
View File
@@ -2,7 +2,7 @@
set -eu
PLUGIN="u-navigator"
VERSION="2026.06.23.r005"
VERSION="2026.06.23.r006"
PKG_DIR="packages"
WORK_DIR=".plugin-build"
PKG_NAME="${PLUGIN}-${VERSION}.tgz"
@@ -13,6 +13,7 @@ mkdir -p "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/assets" "$PKG_DIR"
cp -R plugin-root/usr "$WORK_DIR/"
cp server/public/app.js "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/assets/app.js"
cp server/public/styles.css "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/assets/styles.css"
perl -0pi -e "s/__VERSION__/${VERSION}/g" "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/U-Navigator.page"
tar -czf "$PKG_DIR/$PKG_NAME" -C "$WORK_DIR" usr
rm -rf "$WORK_DIR"