@rubytech/create-realagent 1.0.435 → 1.0.437
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/uninstall.js +44 -26
- package/package.json +1 -1
- package/payload/maxy/server.js +295 -84
- package/payload/platform/neo4j/schema.cypher +6 -0
- package/payload/platform/plugins/admin/mcp/dist/index.js +379 -10
- package/payload/platform/plugins/admin/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/admin/skills/onboarding/skill.md +1 -1
- package/payload/platform/plugins/admin/skills/plugin-management/skill.md +16 -58
- package/payload/platform/plugins/anthropic/PLUGIN.md +2 -2
- package/payload/platform/plugins/contacts/mcp/dist/index.js +34 -16
- package/payload/platform/plugins/contacts/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.d.ts +2 -2
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.d.ts.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.js +34 -9
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.js.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.d.ts +2 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.d.ts.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.js +13 -7
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.js.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.d.ts +2 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.d.ts.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.js +1 -0
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.js.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.d.ts +2 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.d.ts.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.js +10 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.js.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.d.ts +1 -0
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.d.ts.map +1 -1
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.js +8 -4
- package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.js.map +1 -1
- package/payload/platform/plugins/docs/references/contacts-guide.md +7 -5
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.d.ts +1 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js +30 -4
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js.map +1 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js +31 -3
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.d.ts +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.js +30 -2
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.js.map +1 -1
- package/payload/platform/templates/agents/admin/IDENTITY.md +1 -1
package/dist/uninstall.js
CHANGED
|
@@ -4,12 +4,29 @@ import { resolve, join } from "node:path";
|
|
|
4
4
|
import { homedir } from "node:os";
|
|
5
5
|
import { createInterface } from "node:readline";
|
|
6
6
|
const HOME = homedir();
|
|
7
|
-
const
|
|
8
|
-
|
|
7
|
+
const PAYLOAD_DIR = resolve(import.meta.dirname, "../payload");
|
|
8
|
+
// Brand manifest — read from payload to derive brand-specific installation paths.
|
|
9
|
+
// No fallback: if brand.json is missing, the package is corrupted.
|
|
10
|
+
const BRAND_PATH = join(PAYLOAD_DIR, "platform", "config", "brand.json");
|
|
11
|
+
if (!existsSync(BRAND_PATH)) {
|
|
12
|
+
console.error("FATAL: brand.json not found in payload. Package may be corrupted.");
|
|
13
|
+
process.exit(1);
|
|
14
|
+
}
|
|
15
|
+
let BRAND;
|
|
16
|
+
try {
|
|
17
|
+
BRAND = JSON.parse(readFileSync(BRAND_PATH, "utf-8"));
|
|
18
|
+
}
|
|
19
|
+
catch (err) {
|
|
20
|
+
console.error(`FATAL: Failed to parse brand.json: ${err.message}`);
|
|
21
|
+
process.exit(1);
|
|
22
|
+
}
|
|
23
|
+
const INSTALL_DIR = resolve(HOME, BRAND.installDir);
|
|
24
|
+
const CONFIG_DIR = resolve(HOME, BRAND.configDir);
|
|
25
|
+
const LOG_FILE = join("/tmp", `${BRAND.productName.toLowerCase().replace(/\s+/g, "-")}-uninstall-${new Date().toISOString().replace(/[:.]/g, "-")}.log`);
|
|
9
26
|
const TOTAL = "10";
|
|
10
27
|
// ---------------------------------------------------------------------------
|
|
11
28
|
// Logging — timestamped to console AND persistent log file in /tmp
|
|
12
|
-
// (Log lives in /tmp because the uninstall deletes
|
|
29
|
+
// (Log lives in /tmp because the uninstall deletes the config directory)
|
|
13
30
|
// ---------------------------------------------------------------------------
|
|
14
31
|
function logFile(msg) {
|
|
15
32
|
try {
|
|
@@ -67,13 +84,13 @@ export function isMaxyInstalled() {
|
|
|
67
84
|
// ---------------------------------------------------------------------------
|
|
68
85
|
function stopServices() {
|
|
69
86
|
log("1", "Stopping services...");
|
|
70
|
-
// Stop
|
|
87
|
+
// Stop platform user service
|
|
71
88
|
try {
|
|
72
|
-
spawnSync("systemctl", ["--user", "stop", "
|
|
73
|
-
console.log(
|
|
89
|
+
spawnSync("systemctl", ["--user", "stop", BRAND.serviceName.replace(".service", "")], { stdio: "pipe", timeout: 15_000 });
|
|
90
|
+
console.log(` Stopped ${BRAND.serviceName}`);
|
|
74
91
|
}
|
|
75
92
|
catch {
|
|
76
|
-
console.log(
|
|
93
|
+
console.log(` ${BRAND.serviceName} not running`);
|
|
77
94
|
}
|
|
78
95
|
// Stop Neo4j
|
|
79
96
|
try {
|
|
@@ -210,7 +227,7 @@ export function exportData(exportPath) {
|
|
|
210
227
|
console.log(" neo4j-admin not found — skipping database export.");
|
|
211
228
|
}
|
|
212
229
|
// Copy account config
|
|
213
|
-
const accountsDir = resolve(
|
|
230
|
+
const accountsDir = resolve(CONFIG_DIR, "accounts");
|
|
214
231
|
if (existsSync(accountsDir)) {
|
|
215
232
|
try {
|
|
216
233
|
const dest = join(exportPath, "accounts");
|
|
@@ -222,11 +239,11 @@ export function exportData(exportPath) {
|
|
|
222
239
|
}
|
|
223
240
|
}
|
|
224
241
|
else {
|
|
225
|
-
console.log(
|
|
242
|
+
console.log(` No account config found at ${accountsDir}`);
|
|
226
243
|
}
|
|
227
244
|
// Copy secrets (password, API key) so a fresh install could reuse them
|
|
228
245
|
for (const file of [".neo4j-password", ".anthropic-api-key", ".admin-pin"]) {
|
|
229
|
-
const src = resolve(
|
|
246
|
+
const src = resolve(CONFIG_DIR, file);
|
|
230
247
|
if (existsSync(src)) {
|
|
231
248
|
try {
|
|
232
249
|
cpSync(src, join(exportPath, file));
|
|
@@ -243,8 +260,8 @@ export function exportData(exportPath) {
|
|
|
243
260
|
function removeAppDirs() {
|
|
244
261
|
log("4", "Removing application directories...");
|
|
245
262
|
const dirs = [
|
|
246
|
-
{ path:
|
|
247
|
-
{ path:
|
|
263
|
+
{ path: INSTALL_DIR, label: `~/${BRAND.installDir}` },
|
|
264
|
+
{ path: CONFIG_DIR, label: `~/${BRAND.configDir}` },
|
|
248
265
|
{ path: resolve(HOME, ".cloudflared"), label: "~/.cloudflared" },
|
|
249
266
|
{ path: resolve(HOME, ".claude"), label: "~/.claude" },
|
|
250
267
|
{ path: resolve(HOME, ".ollama"), label: "~/.ollama" },
|
|
@@ -336,8 +353,8 @@ function removeSystemConfig() {
|
|
|
336
353
|
return;
|
|
337
354
|
}
|
|
338
355
|
const files = [
|
|
339
|
-
{ path:
|
|
340
|
-
{ path:
|
|
356
|
+
{ path: `/etc/avahi/services/${BRAND.hostname}.service`, label: "Avahi mDNS service" },
|
|
357
|
+
{ path: `/etc/NetworkManager/conf.d/${BRAND.hostname}-no-powersave.conf`, label: "WiFi power save config" },
|
|
341
358
|
{ path: "/etc/apt/sources.list.d/neo4j.list", label: "Neo4j apt repository" },
|
|
342
359
|
{ path: "/usr/share/keyrings/neo4j.gpg", label: "Neo4j GPG key" },
|
|
343
360
|
];
|
|
@@ -364,16 +381,17 @@ function removeSystemConfig() {
|
|
|
364
381
|
function removeSystemdService() {
|
|
365
382
|
log("8", "Removing systemd service...");
|
|
366
383
|
// Disable the service
|
|
384
|
+
const svcUnit = BRAND.serviceName.replace(".service", "");
|
|
367
385
|
try {
|
|
368
|
-
spawnSync("systemctl", ["--user", "disable",
|
|
386
|
+
spawnSync("systemctl", ["--user", "disable", svcUnit], { stdio: "pipe" });
|
|
369
387
|
}
|
|
370
388
|
catch { /* already disabled or missing */ }
|
|
371
389
|
// Remove service file
|
|
372
|
-
const serviceFile = resolve(HOME,
|
|
390
|
+
const serviceFile = resolve(HOME, `.config/systemd/user/${BRAND.serviceName}`);
|
|
373
391
|
if (existsSync(serviceFile)) {
|
|
374
392
|
try {
|
|
375
393
|
rmSync(serviceFile);
|
|
376
|
-
console.log(
|
|
394
|
+
console.log(` Removed ${BRAND.serviceName}`);
|
|
377
395
|
}
|
|
378
396
|
catch (err) {
|
|
379
397
|
console.log(` Failed to remove service file: ${err instanceof Error ? err.message : String(err)}`);
|
|
@@ -440,8 +458,8 @@ function restoreHostname() {
|
|
|
440
458
|
}
|
|
441
459
|
try {
|
|
442
460
|
const hostname = execFileSync("hostname", [], { encoding: "utf-8" }).trim();
|
|
443
|
-
if (hostname !==
|
|
444
|
-
console.log(` Hostname is '${hostname}' — not '
|
|
461
|
+
if (hostname !== BRAND.hostname) {
|
|
462
|
+
console.log(` Hostname is '${hostname}' — not '${BRAND.hostname}', nothing to restore.`);
|
|
445
463
|
return;
|
|
446
464
|
}
|
|
447
465
|
// The installer doesn't save the original hostname, so we use a sensible default
|
|
@@ -461,14 +479,14 @@ function showRemovalSummary() {
|
|
|
461
479
|
console.log("");
|
|
462
480
|
console.log("The following will be removed:");
|
|
463
481
|
console.log("");
|
|
464
|
-
console.log(
|
|
465
|
-
console.log(
|
|
482
|
+
console.log(` Services: ${BRAND.serviceName}, Neo4j, cloudflared, VNC, Ollama`);
|
|
483
|
+
console.log(` App dirs: ~/${BRAND.installDir}/, ~/${BRAND.configDir}/, ~/.claude/, ~/.cloudflared/, ~/.ollama/`);
|
|
466
484
|
console.log(" Database: Neo4j data and transaction logs");
|
|
467
485
|
console.log(" Packages: neo4j, openjdk-17, tigervnc, websockify, novnc, cloudflared");
|
|
468
486
|
console.log(" Config: avahi service, WiFi power save, apt repos, GPG keys");
|
|
469
|
-
console.log(
|
|
487
|
+
console.log(` Systemd: ${BRAND.serviceName} unit file, user lingering`);
|
|
470
488
|
console.log(" Ollama: binary and models");
|
|
471
|
-
console.log(
|
|
489
|
+
console.log(` Hostname: restored from '${BRAND.hostname}' to 'raspberrypi'`);
|
|
472
490
|
console.log(" Cloudflare: tunnel and DNS records deleted from Cloudflare's edge");
|
|
473
491
|
console.log("");
|
|
474
492
|
console.log(" Node.js and shared system utilities (curl, git, etc.) are NOT removed.");
|
|
@@ -492,13 +510,13 @@ async function confirmUninstall() {
|
|
|
492
510
|
export async function runUninstall(options) {
|
|
493
511
|
const PKG_VERSION = JSON.parse(readFileSync(resolve(import.meta.dirname, "../package.json"), "utf-8")).version;
|
|
494
512
|
console.log("================================================================");
|
|
495
|
-
console.log(`
|
|
513
|
+
console.log(` ${BRAND.productName} Uninstall (create-maxy v${PKG_VERSION})`);
|
|
496
514
|
console.log("================================================================");
|
|
497
515
|
console.log(` Log: ${LOG_FILE}`);
|
|
498
516
|
console.log("");
|
|
499
517
|
// Check if Maxy is installed
|
|
500
518
|
if (!isMaxyInstalled()) {
|
|
501
|
-
console.error(
|
|
519
|
+
console.error(`${BRAND.productName} is not installed (~/${BRAND.installDir} not found). Nothing to uninstall.`);
|
|
502
520
|
process.exit(1);
|
|
503
521
|
}
|
|
504
522
|
// Show what will be removed
|
|
@@ -546,7 +564,7 @@ export async function runUninstall(options) {
|
|
|
546
564
|
console.log("================================================================");
|
|
547
565
|
if (failures.length === 0) {
|
|
548
566
|
console.log("");
|
|
549
|
-
console.log(
|
|
567
|
+
console.log(` ${BRAND.productName} has been completely removed.`);
|
|
550
568
|
console.log("");
|
|
551
569
|
console.log(" To reinstall: npx -y @rubytech/create-maxy");
|
|
552
570
|
}
|