@hienlh/ppm 0.8.57 → 0.8.58

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.8.58] - 2026-03-26
4
+
5
+ ### Fixed
6
+ - **Stale upgrade banner**: Banner showed old version (e.g. v0.8.56) even after upgrading past it. Route now compares availableVersion > currentVersion before returning. Supervisor clears stale availableVersion on startup.
7
+
3
8
  ## [0.8.57] - 2026-03-26
4
9
 
5
10
  ### Fixed
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hienlh/ppm",
3
- "version": "0.8.57",
3
+ "version": "0.8.58",
4
4
  "description": "Personal Project Manager — mobile-first web IDE with AI assistance",
5
5
  "author": "hienlh",
6
6
  "license": "MIT",
@@ -5,6 +5,7 @@ import { readFileSync, existsSync } from "node:fs";
5
5
  import { VERSION } from "../../version.ts";
6
6
  import {
7
7
  getInstallMethod,
8
+ compareSemver,
8
9
  applyUpgrade,
9
10
  signalSupervisorUpgrade,
10
11
  } from "../../services/upgrade.service.ts";
@@ -20,7 +21,11 @@ upgradeRoutes.get("/", (c) => {
20
21
  try {
21
22
  if (existsSync(STATUS_FILE)) {
22
23
  const data = JSON.parse(readFileSync(STATUS_FILE, "utf-8"));
23
- availableVersion = data.availableVersion ?? null;
24
+ const candidate = data.availableVersion ?? null;
25
+ // Only report if actually newer than current version
26
+ if (candidate && compareSemver(VERSION, candidate) < 0) {
27
+ availableVersion = candidate;
28
+ }
24
29
  }
25
30
  } catch {}
26
31
 
@@ -407,9 +407,9 @@ export async function runSupervisor(opts: {
407
407
  const logFd = openSync(LOG_FILE, "a");
408
408
  log("INFO", `Supervisor started (PID: ${process.pid}, port: ${opts.port}, share: ${opts.share})`);
409
409
 
410
- // Write supervisor PID
410
+ // Write supervisor PID + clear stale availableVersion from previous run
411
411
  writeFileSync(PID_FILE, String(process.pid));
412
- updateStatus({ supervisorPid: process.pid, port: opts.port, host: opts.host });
412
+ updateStatus({ supervisorPid: process.pid, port: opts.port, host: opts.host, availableVersion: null });
413
413
 
414
414
  // Build __serve__ args
415
415
  const serverArgs = [