@rubytech/create-maxy 1.0.500 → 1.0.502

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/dist/index.js CHANGED
@@ -472,8 +472,12 @@ function installNeo4j() {
472
472
  if (!isLinux()) {
473
473
  throw new Error("Automatic Neo4j installation is only supported on Linux. Install Neo4j 5.11+ manually.");
474
474
  }
475
- console.log(" Installing Java 17...");
476
- shell("apt-get", ["install", "-y", "openjdk-17-jre-headless"], { sudo: true });
475
+ // Neo4j 5.x supports Java 17 and 21. Debian Bookworm ships 17, Trixie ships 21.
476
+ const javaPackage = spawnSync("apt-cache", ["show", "openjdk-17-jre-headless"], { stdio: "pipe" }).status === 0
477
+ ? "openjdk-17-jre-headless"
478
+ : "openjdk-21-jre-headless";
479
+ console.log(` Installing Java (${javaPackage})...`);
480
+ shell("apt-get", ["install", "-y", javaPackage], { sudo: true });
477
481
  spawnSync("bash", ["-c", "curl -fsSL https://debian.neo4j.com/neotechnology.gpg.key | sudo gpg --yes --dearmor -o /usr/share/keyrings/neo4j.gpg 2>/dev/null"], { stdio: "inherit" });
478
482
  spawnSync("bash", ["-c", 'echo "deb [signed-by=/usr/share/keyrings/neo4j.gpg] https://debian.neo4j.com stable 5" | sudo tee /etc/apt/sources.list.d/neo4j.list'], { stdio: "inherit" });
479
483
  shell("apt-get", ["update"], { sudo: true });
package/dist/uninstall.js CHANGED
@@ -314,6 +314,7 @@ function purgeSystemPackages() {
314
314
  const packages = [
315
315
  "neo4j",
316
316
  "openjdk-17-jre-headless",
317
+ "openjdk-21-jre-headless",
317
318
  "tigervnc-standalone-server",
318
319
  "python3-websockify",
319
320
  "novnc",
@@ -482,7 +483,7 @@ function showRemovalSummary() {
482
483
  console.log(` Services: ${BRAND.serviceName}, Neo4j, cloudflared, VNC, Ollama`);
483
484
  console.log(` App dirs: ~/${BRAND.installDir}/, ~/${BRAND.configDir}/, ~/.claude/, ~/.cloudflared/, ~/.ollama/`);
484
485
  console.log(" Database: Neo4j data and transaction logs");
485
- console.log(" Packages: neo4j, openjdk-17, tigervnc, websockify, novnc, cloudflared");
486
+ console.log(" Packages: neo4j, openjdk (17 or 21), tigervnc, websockify, novnc, cloudflared");
486
487
  console.log(" Config: avahi service, WiFi power save, apt repos, GPG keys");
487
488
  console.log(` Systemd: ${BRAND.serviceName} unit file, user lingering`);
488
489
  console.log(" Ollama: binary and models");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rubytech/create-maxy",
3
- "version": "1.0.500",
3
+ "version": "1.0.502",
4
4
  "description": "Install Maxy — AI for Productive People",
5
5
  "bin": {
6
6
  "create-maxy": "./dist/index.js"
@@ -95,14 +95,15 @@ if [ -f "$USER_MD" ]; then
95
95
  OWNER_LOCATION=$(sed -n 's/.*\*\*Location:\*\* *//p' "$USER_MD" | head -1)
96
96
  OWNER_HOURS=$(sed -n 's/.*\*\*Working hours:\*\* *//p' "$USER_MD" | head -1)
97
97
 
98
- python3 -c "
98
+ python3 - "$OWNER_NAME" "$OWNER_PHONE" "$OWNER_BUSINESS" "$OWNER_LOCATION" "$OWNER_HOURS" "$OUTPUT_DIR" <<'PYEOF'
99
99
  import json, sys
100
+ name, phone, business, location, hours, out = sys.argv[1:7]
100
101
  d = {}
101
- for k, v in [('name','$OWNER_NAME'),('phone','$OWNER_PHONE'),('business','$OWNER_BUSINESS'),('location','$OWNER_LOCATION'),('hours','$OWNER_HOURS')]:
102
+ for k, v in [('name',name),('phone',phone),('business',business),('location',location),('hours',hours)]:
102
103
  if v: d[k] = v
103
- json.dump(d, open('$OUTPUT_DIR/identity/owner.json','w'), indent=2)
104
- print(f'[export] identity/owner.json written ({d.get(\"name\",\"unknown\")})')
105
- "
104
+ json.dump(d, open(f'{out}/identity/owner.json','w'), indent=2)
105
+ print(f'[export] identity/owner.json written ({d.get("name","unknown")})')
106
+ PYEOF
106
107
  else
107
108
  echo "[export] WARN: USER.md not found at $USER_MD — owner identity skipped"
108
109
  fi
@@ -5315,6 +5315,9 @@ function getUserIdForSession(sessionKey) {
5315
5315
  function getUserNameForSession(sessionKey) {
5316
5316
  return sessionStore.get(sessionKey)?.userName;
5317
5317
  }
5318
+ function getConversationIdForSession(sessionKey) {
5319
+ return sessionStore.get(sessionKey)?.conversationId;
5320
+ }
5318
5321
  function registerGrantSession(sessionKey, accountId, agentName, opts) {
5319
5322
  sessionStore.set(sessionKey, {
5320
5323
  createdAt: Date.now(),
@@ -8108,7 +8111,7 @@ async function POST2(req) {
8108
8111
  );
8109
8112
  }
8110
8113
  const sseLog = agentLogStream("sse-events", account.accountDir);
8111
- const sk = session_key.slice(0, 8);
8114
+ const sk = getConversationIdForSession(session_key)?.slice(0, 8) ?? session_key.slice(0, 8);
8112
8115
  const agentName = getAgentNameForSession(session_key);
8113
8116
  if (!agentName) {
8114
8117
  console.log(`[chat] no agent for session=${sk} \u2014 session expired or server restarted`);
@@ -26443,7 +26446,7 @@ async function createAdminSession(accountId, thinkingView, userId, userName) {
26443
26446
  console.log(`[managed-resume] ${(/* @__PURE__ */ new Date()).toISOString()} conversationId=${conversationId.slice(0, 8)}\u2026 loaded=${loadedMessages} messages (${estimatedTokens} estimated tokens)`);
26444
26447
  }
26445
26448
  }
26446
- console.log(`[session] ${(/* @__PURE__ */ new Date()).toISOString()} admin session created: userId=${userId ?? "\u2013"} userName=${userName ?? "\u2013"} accountId=${accountId} conversationId=${conversationId?.slice(0, 8) ?? "\u2013"}`);
26449
+ console.log(`[session] ${(/* @__PURE__ */ new Date()).toISOString()} admin session created: userId=${userId ?? "\u2013"} userName=${userName ?? "\u2013"} accountId=${accountId} conversationId=${conversationId?.slice(0, 8) ?? "\u2013"} sessionKey=${sessionKey.slice(0, 8)}`);
26447
26450
  return Response.json({
26448
26451
  session_key: sessionKey,
26449
26452
  agent_id: "admin",
@@ -26633,7 +26636,7 @@ async function POST20(req) {
26633
26636
  }
26634
26637
  const encoder = new TextEncoder();
26635
26638
  const sseLog = agentLogStream("sse-events", account.accountDir);
26636
- const sk = session_key.slice(0, 8);
26639
+ const sk = getConversationIdForSession(session_key)?.slice(0, 8) ?? session_key.slice(0, 8);
26637
26640
  const readable = new ReadableStream({
26638
26641
  async start(controller) {
26639
26642
  try {