shieldcortex 2.4.10 → 2.4.12

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.
Files changed (63) hide show
  1. package/dashboard/.next/standalone/dashboard/.next/BUILD_ID +1 -1
  2. package/dashboard/.next/standalone/dashboard/.next/build-manifest.json +2 -2
  3. package/dashboard/.next/standalone/dashboard/.next/prerender-manifest.json +3 -3
  4. package/dashboard/.next/standalone/dashboard/.next/required-server-files.json +4 -4
  5. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.html +2 -2
  6. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.rsc +1 -1
  7. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  8. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  9. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  10. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  11. package/dashboard/.next/standalone/dashboard/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  12. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.html +1 -1
  13. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.rsc +1 -1
  14. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  15. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  16. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  17. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  18. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  19. package/dashboard/.next/standalone/dashboard/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  20. package/dashboard/.next/standalone/dashboard/.next/server/app/index.html +1 -1
  21. package/dashboard/.next/standalone/dashboard/.next/server/app/index.rsc +1 -1
  22. package/dashboard/.next/standalone/dashboard/.next/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  23. package/dashboard/.next/standalone/dashboard/.next/server/app/index.segments/_full.segment.rsc +1 -1
  24. package/dashboard/.next/standalone/dashboard/.next/server/app/index.segments/_head.segment.rsc +1 -1
  25. package/dashboard/.next/standalone/dashboard/.next/server/app/index.segments/_index.segment.rsc +1 -1
  26. package/dashboard/.next/standalone/dashboard/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  27. package/dashboard/.next/standalone/dashboard/.next/server/pages/404.html +1 -1
  28. package/dashboard/.next/standalone/dashboard/.next/server/pages/500.html +2 -2
  29. package/dashboard/.next/standalone/dashboard/.next/server/server-reference-manifest.js +1 -1
  30. package/dashboard/.next/standalone/dashboard/.next/server/server-reference-manifest.json +1 -1
  31. package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/README.md +2 -2
  32. package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/lib/glib-2.0/include/glibconfig.h +9 -8
  33. package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64/lib/libvips-cpp.8.17.3.dylib → sharp-libvips-linux-x64/lib/libvips-cpp.so.8.17.3} +0 -0
  34. package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/package.json +11 -5
  35. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/README.md +46 -0
  36. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/glib-2.0/include/glibconfig.h +221 -0
  37. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/index.js +1 -0
  38. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/libvips-cpp.so.8.17.3 +0 -0
  39. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/package.json +42 -0
  40. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-libvips-linuxmusl-x64/versions.json +30 -0
  41. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-linux-x64/lib/sharp-linux-x64.node +0 -0
  42. package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-darwin-arm64 → sharp-linux-x64}/package.json +13 -7
  43. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-linuxmusl-x64/lib/sharp-linuxmusl-x64.node +0 -0
  44. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-linuxmusl-x64/package.json +46 -0
  45. package/dashboard/.next/standalone/dashboard/server.js +1 -1
  46. package/dashboard/.next/standalone/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/package.json +11 -5
  47. package/dashboard/.next/standalone/node_modules/@img/sharp-libvips-linuxmusl-x64/package.json +42 -0
  48. package/dashboard/.next/standalone/node_modules/@img/{sharp-darwin-arm64 → sharp-linux-x64}/package.json +13 -7
  49. package/dashboard/.next/standalone/node_modules/@img/sharp-linuxmusl-x64/package.json +46 -0
  50. package/dist/index.js +0 -0
  51. package/hooks/openclaw/cortex-memory/HOOK.md +30 -2
  52. package/hooks/openclaw/cortex-memory/handler.js +110 -24
  53. package/package.json +1 -1
  54. package/dashboard/.next/standalone/dashboard/node_modules/@img/sharp-darwin-arm64/lib/sharp-darwin-arm64.node +0 -0
  55. package/dist/setup/clawdbot.d.ts +0 -15
  56. package/dist/setup/clawdbot.d.ts.map +0 -1
  57. package/dist/setup/clawdbot.js +0 -118
  58. package/dist/setup/clawdbot.js.map +0 -1
  59. /package/dashboard/.next/standalone/dashboard/.next/static/{iswq9TJJVHZDUWYSMMM-2 → j3yGjZ6Ts_LmQ9u4uPtD1}/_buildManifest.js +0 -0
  60. /package/dashboard/.next/standalone/dashboard/.next/static/{iswq9TJJVHZDUWYSMMM-2 → j3yGjZ6Ts_LmQ9u4uPtD1}/_clientMiddlewareManifest.json +0 -0
  61. /package/dashboard/.next/standalone/dashboard/.next/static/{iswq9TJJVHZDUWYSMMM-2 → j3yGjZ6Ts_LmQ9u4uPtD1}/_ssgManifest.js +0 -0
  62. /package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/lib/index.js +0 -0
  63. /package/dashboard/.next/standalone/dashboard/node_modules/@img/{sharp-libvips-darwin-arm64 → sharp-libvips-linux-x64}/versions.json +0 -0
@@ -1,118 +0,0 @@
1
- /**
2
- * OpenClaw/Clawdbot hook installer.
3
- *
4
- * Copies the cortex-memory hook into Clawdbot's bundled hooks directory.
5
- * Only works if OpenClaw is installed on the system.
6
- */
7
- import fs from 'fs';
8
- import path from 'path';
9
- import { execSync } from 'child_process';
10
- import { fileURLToPath } from 'url';
11
- const __filename = fileURLToPath(import.meta.url);
12
- const __dirname = path.dirname(__filename);
13
- const HOOK_NAME = 'cortex-memory';
14
- // Hook source is in hooks/clawdbot/cortex-memory/ relative to project root
15
- // From dist/setup/, go up two levels to project root
16
- const HOOK_SOURCE = path.resolve(__dirname, '..', '..', 'hooks', 'clawdbot', HOOK_NAME);
17
- /**
18
- * Find Clawdbot's bundled hooks directory by locating the binary
19
- */
20
- export function findClawdbotHooksDir() {
21
- try {
22
- const binPath = execSync('which openclaw 2>/dev/null || which clawdbot 2>/dev/null || which moltbot 2>/dev/null', {
23
- encoding: 'utf-8',
24
- }).trim();
25
- if (!binPath)
26
- return null;
27
- // Resolve symlink — lands in e.g. <prefix>/lib/node_modules/clawdbot/dist/entry.js
28
- const realBin = fs.realpathSync(binPath);
29
- // Walk up from resolved path to find dist/hooks/bundled/
30
- let dir = path.dirname(realBin);
31
- for (let i = 0; i < 5; i++) {
32
- const candidate = path.join(dir, 'hooks', 'bundled');
33
- if (fs.existsSync(candidate)) {
34
- return candidate;
35
- }
36
- // Also check dist/hooks/bundled from current dir
37
- const distCandidate = path.join(dir, 'dist', 'hooks', 'bundled');
38
- if (fs.existsSync(distCandidate)) {
39
- return distCandidate;
40
- }
41
- dir = path.dirname(dir);
42
- }
43
- return null;
44
- }
45
- catch {
46
- return null;
47
- }
48
- }
49
- export async function installClawdbotHook() {
50
- const hooksDir = findClawdbotHooksDir();
51
- if (!hooksDir) {
52
- console.error('OpenClaw/Clawdbot is not installed on this system.');
53
- console.log('Install it first: npm install -g openclaw');
54
- process.exit(1);
55
- }
56
- if (!fs.existsSync(HOOK_SOURCE)) {
57
- console.error('Hook source files not found. Package may be corrupted.');
58
- process.exit(1);
59
- }
60
- const destDir = path.join(hooksDir, HOOK_NAME);
61
- // Copy hook files
62
- fs.mkdirSync(destDir, { recursive: true });
63
- for (const file of ['HOOK.md', 'handler.js']) {
64
- const src = path.join(HOOK_SOURCE, file);
65
- const dest = path.join(destDir, file);
66
- fs.copyFileSync(src, dest);
67
- }
68
- console.log(`✓ Installed cortex-memory hook to ${destDir}`);
69
- console.log(' The hook will activate on next OpenClaw restart.');
70
- console.log('');
71
- console.log(' What it does:');
72
- console.log(' • Auto-saves important session context on /new');
73
- console.log(' • Injects past memories on session start');
74
- console.log(' • "remember this: ..." keyword trigger');
75
- }
76
- export async function uninstallClawdbotHook() {
77
- const hooksDir = findClawdbotHooksDir();
78
- if (!hooksDir) {
79
- console.log('OpenClaw/Clawdbot is not installed on this system.');
80
- return;
81
- }
82
- const destDir = path.join(hooksDir, HOOK_NAME);
83
- if (!fs.existsSync(destDir)) {
84
- console.log('cortex-memory hook is not installed.');
85
- return;
86
- }
87
- fs.rmSync(destDir, { recursive: true });
88
- console.log(`✓ Removed cortex-memory hook from ${destDir}`);
89
- }
90
- export async function clawdbotHookStatus() {
91
- const hooksDir = findClawdbotHooksDir();
92
- if (!hooksDir) {
93
- console.log('OpenClaw/Clawdbot: not installed');
94
- return;
95
- }
96
- const destDir = path.join(hooksDir, HOOK_NAME);
97
- const installed = fs.existsSync(destDir);
98
- console.log(`OpenClaw/Clawdbot: installed`);
99
- console.log(`Hooks directory: ${hooksDir}`);
100
- console.log(`cortex-memory: ${installed ? 'installed' : 'not installed'}`);
101
- }
102
- export async function handleClawdbotCommand(subcommand) {
103
- switch (subcommand) {
104
- case 'install':
105
- await installClawdbotHook();
106
- break;
107
- case 'uninstall':
108
- await uninstallClawdbotHook();
109
- break;
110
- case 'status':
111
- await clawdbotHookStatus();
112
- break;
113
- default:
114
- console.log('Usage: shieldcortex clawdbot <install|uninstall|status>');
115
- process.exit(1);
116
- }
117
- }
118
- //# sourceMappingURL=clawdbot.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"clawdbot.js","sourceRoot":"","sources":["../../src/setup/clawdbot.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,MAAM,IAAI,CAAC;AACpB,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AAEpC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;AAE3C,MAAM,SAAS,GAAG,eAAe,CAAC;AAElC,2EAA2E;AAC3E,qDAAqD;AACrD,MAAM,WAAW,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,UAAU,EAAE,SAAS,CAAC,CAAC;AAExF;;GAEG;AACH,MAAM,UAAU,oBAAoB;IAClC,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,QAAQ,CAAC,uFAAuF,EAAE;YAChH,QAAQ,EAAE,OAAO;SAClB,CAAC,CAAC,IAAI,EAAE,CAAC;QAEV,IAAI,CAAC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