Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
fix: address round 16 Copilot review feedback
Adam Eivy745fe8fa2e0a
diff --git a/client/src/components/apps/tabs/UpdateTab.jsx b/client/src/components/apps/tabs/UpdateTab.jsxindex f5cfbdcaf0..98636c6c93 100644--- a/client/src/components/apps/tabs/UpdateTab.jsx+++ b/client/src/components/apps/tabs/UpdateTab.jsx@@ -10,7 +10,6 @@ const STEP_LABELS = {'git-fetch': 'Fetching tags','git-checkout': 'Checking out release','npm-install': 'Installing dependencies',- setup: 'Running setup',migrations: 'Running migrations',build: 'Building client',restart: 'Restarting PortOS',diff --git a/scripts/portos-update.sh b/scripts/portos-update.shindex 836aba4487..ea5a15f112 100755--- a/scripts/portos-update.sh+++ b/scripts/portos-update.sh@@ -38,29 +38,24 @@ step "git-checkout" "running" "Checking out $TAG..."git checkout "$TAG" >> "$LOG_FILE" 2>&1step "git-checkout" "done" "Checked out $TAG"-# Step 3: npm install-step "npm-install" "running" "Installing dependencies..."-npm install >> "$LOG_FILE" 2>&1+# Step 3: npm install (root + client + server + setup)+step "npm-install" "running" "Installing all dependencies..."+npm run install:all >> "$LOG_FILE" 2>&1step "npm-install" "done" "Dependencies installed"-# Step 4: Setup (data dirs, db, browser)-step "setup" "running" "Running setup..."-npm run setup >> "$LOG_FILE" 2>&1-step "setup" "done" "Setup complete"--# Step 5: Migrations+# Step 4: Migrationsstep "migrations" "running" "Running data migrations..."if [ -f "$ROOT_DIR/scripts/run-migrations.js" ]; thennode "$ROOT_DIR/scripts/run-migrations.js" >> "$LOG_FILE" 2>&1fistep "migrations" "done" "Migrations complete"-# Step 6: Build client+# Step 5: Build clientstep "build" "running" "Building client..."npm run build --prefix client >> "$LOG_FILE" 2>&1step "build" "done" "Client built"-# Step 7: Restart via PM2+# Step 6: Restart via PM2step "restart" "running" "Restarting PortOS..."log "=== PortOS update to $TAG restarting ==="diff --git a/server/services/updateChecker.js b/server/services/updateChecker.jsindex 230c3ff4a2..e4d06ea46c 100644--- a/server/services/updateChecker.js+++ b/server/services/updateChecker.js@@ -45,6 +45,30 @@ export function compareSemver(a, b) {const [core, pre] = v.split('+')[0].split('-', 2);return { nums: core.split('.').map(Number), pre: pre || null };};+ const comparePreRelease = (preA, preB) => {+ const segsA = preA.split('.');+ const segsB = preB.split('.');+ const len = Math.max(segsA.length, segsB.length);+ for (let i = 0; i < len; i++) {+ if (i >= segsA.length) return -1; // fewer segments = lower precedence+ if (i >= segsB.length) return 1;+ const numA = /^\d+$/.test(segsA[i]) ? Number(segsA[i]) : null;+ const numB = /^\d+$/.test(segsB[i]) ? Number(segsB[i]) : null;+ // Numeric identifiers sort before string identifiers+ if (numA !== null && numB !== null) {+ if (numA < numB) return -1;+ if (numA > numB) return 1;+ } else if (numA !== null) {+ return -1;+ } else if (numB !== null) {+ return 1;+ } else {+ if (segsA[i] < segsB[i]) return -1;+ if (segsA[i] > segsB[i]) return 1;+ }+ }+ return 0;+ };const pa = extractParts(a);const pb = extractParts(b);for (let i = 0; i < 3; i++) {@@ -56,7 +80,7 @@ export function compareSemver(a, b) {// Equal core versions: no pre-release > pre-release (1.0.0 > 1.0.0-rc.1)if (!pa.pre && pb.pre) return 1;if (pa.pre && !pb.pre) return -1;- if (pa.pre && pb.pre) return pa.pre < pb.pre ? -1 : pa.pre > pb.pre ? 1 : 0;+ if (pa.pre && pb.pre) return comparePreRelease(pa.pre, pb.pre);return 0;}