plc-checkweigher 1.38.2 → 1.38.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -760,6 +760,10 @@ fix)
760
760
 
761
761
  LOG_DIR="/home/pi/reports/logs"
762
762
  mkdir -p "$LOG_DIR" 2>/dev/null || true
763
+ # Keep the dir owned by pi so the (pi) web "Backup & Clear" can delete its
764
+ # contents — this CLI runs as root and would otherwise lock the folder.
765
+ chown pi:pi "$LOG_DIR" 2>/dev/null || true
766
+ chmod 775 "$LOG_DIR" 2>/dev/null || true
763
767
  # Build mode tag: "all" or hyphen-joined active scopes
764
768
  _LOG_MODES=""
765
769
  [[ $FIX_WIFI -eq 1 ]] && _LOG_MODES="${_LOG_MODES:+${_LOG_MODES}-}wifi"
@@ -1359,6 +1363,8 @@ update)
1359
1363
  # ── Update report log (pushed to SMB at the end) ──────────────────────────
1360
1364
  ULOG_DIR="/home/pi/reports/logs"
1361
1365
  mkdir -p "$ULOG_DIR" 2>/dev/null || true
1366
+ chown pi:pi "$ULOG_DIR" 2>/dev/null || true
1367
+ chmod 775 "$ULOG_DIR" 2>/dev/null || true
1362
1368
  ULOG="${ULOG_DIR}/update_$(date '+%Y%m%d_%H%M%S').log"
1363
1369
  ulog() { echo "[$(date '+%Y-%m-%d %H:%M:%S')] $*" >> "$ULOG"; }
1364
1370
  ulog "=== Update started ==="
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plc-checkweigher",
3
- "version": "1.38.2",
3
+ "version": "1.38.4",
4
4
  "description": "One-command installer for the PLC Check-Weigher system on Raspberry Pi (PREEMPT_RT kernel, Python stack, WiFi, SMB, systemd RT services)",
5
5
  "scripts": {
6
6
  "postinstall": "node bin/cli.js"