@akon-labs/nexus-cli 0.1.10 → 0.1.11
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/cli/require-login.d.ts.map +1 -1
- package/dist/cli/require-login.js +2 -2
- package/dist/cli/require-login.js.map +1 -1
- package/dist/cli.js +2492 -1088
- package/dist/core/agent-session.d.ts +3 -1
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +4 -0
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/loader.d.ts.map +1 -1
- package/dist/core/extensions/loader.js +6 -0
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +7 -1
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +14 -0
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/types.d.ts +18 -0
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/graph-rail-store.d.ts +10 -0
- package/dist/core/graph-rail-store.d.ts.map +1 -1
- package/dist/core/graph-rail-store.js +9 -0
- package/dist/core/graph-rail-store.js.map +1 -1
- package/dist/core/keybindings.d.ts +2 -1
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +4 -1
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/tools/find.d.ts.map +1 -1
- package/dist/core/tools/find.js +1 -1
- package/dist/core/tools/find.js.map +1 -1
- package/dist/core/tools/grep.d.ts.map +1 -1
- package/dist/core/tools/grep.js +1 -1
- package/dist/core/tools/grep.js.map +1 -1
- package/dist/extensions/gitnexus/client.d.ts.map +1 -1
- package/dist/extensions/gitnexus/client.js +45 -14
- package/dist/extensions/gitnexus/client.js.map +1 -1
- package/dist/extensions/gitnexus/config.d.ts +15 -1
- package/dist/extensions/gitnexus/config.d.ts.map +1 -1
- package/dist/extensions/gitnexus/config.js +86 -2
- package/dist/extensions/gitnexus/config.js.map +1 -1
- package/dist/extensions/gitnexus/hub-api.d.ts +56 -0
- package/dist/extensions/gitnexus/hub-api.d.ts.map +1 -0
- package/dist/extensions/gitnexus/hub-api.js +105 -0
- package/dist/extensions/gitnexus/hub-api.js.map +1 -0
- package/dist/extensions/gitnexus/index-repo.d.ts +50 -0
- package/dist/extensions/gitnexus/index-repo.d.ts.map +1 -0
- package/dist/extensions/gitnexus/index-repo.js +162 -0
- package/dist/extensions/gitnexus/index-repo.js.map +1 -0
- package/dist/extensions/gitnexus/index.d.ts.map +1 -1
- package/dist/extensions/gitnexus/index.js +137 -17
- package/dist/extensions/gitnexus/index.js.map +1 -1
- package/dist/extensions/gitnexus/observatory.d.ts.map +1 -1
- package/dist/extensions/gitnexus/observatory.js +2 -2
- package/dist/extensions/gitnexus/observatory.js.map +1 -1
- package/dist/extensions/gitnexus/resolve.d.ts +9 -0
- package/dist/extensions/gitnexus/resolve.d.ts.map +1 -1
- package/dist/extensions/gitnexus/resolve.js +52 -2
- package/dist/extensions/gitnexus/resolve.js.map +1 -1
- package/dist/extensions/index.d.ts.map +1 -1
- package/dist/extensions/index.js +3 -0
- package/dist/extensions/index.js.map +1 -1
- package/dist/extensions/mcp/commands.d.ts +22 -2
- package/dist/extensions/mcp/commands.d.ts.map +1 -1
- package/dist/extensions/mcp/commands.js +201 -9
- package/dist/extensions/mcp/commands.js.map +1 -1
- package/dist/extensions/mcp/config.d.ts +2 -0
- package/dist/extensions/mcp/config.d.ts.map +1 -1
- package/dist/extensions/mcp/config.js +6 -1
- package/dist/extensions/mcp/config.js.map +1 -1
- package/dist/extensions/mcp/index.d.ts.map +1 -1
- package/dist/extensions/mcp/index.js +54 -5
- package/dist/extensions/mcp/index.js.map +1 -1
- package/dist/extensions/mcp/mcp-setup-panel.d.ts +63 -2
- package/dist/extensions/mcp/mcp-setup-panel.d.ts.map +1 -1
- package/dist/extensions/mcp/mcp-setup-panel.js +563 -77
- package/dist/extensions/mcp/mcp-setup-panel.js.map +1 -1
- package/dist/extensions/subagent/index.d.ts +2 -1
- package/dist/extensions/subagent/index.d.ts.map +1 -1
- package/dist/extensions/subagent/index.js +19 -6
- package/dist/extensions/subagent/index.js.map +1 -1
- package/dist/extensions/subagent-render.d.ts +3 -0
- package/dist/extensions/subagent-render.d.ts.map +1 -0
- package/dist/extensions/subagent-render.js +39 -0
- package/dist/extensions/subagent-render.js.map +1 -0
- package/dist/index.js +2524 -1120
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +2 -0
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/command-palette.d.ts +2 -1
- package/dist/modes/interactive/components/command-palette.d.ts.map +1 -1
- package/dist/modes/interactive/components/command-palette.js +11 -4
- package/dist/modes/interactive/components/command-palette.js.map +1 -1
- package/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/dist/modes/interactive/components/footer.js +9 -3
- package/dist/modes/interactive/components/footer.js.map +1 -1
- package/dist/modes/interactive/components/graph-rail.d.ts.map +1 -1
- package/dist/modes/interactive/components/graph-rail.js +18 -3
- package/dist/modes/interactive/components/graph-rail.js.map +1 -1
- package/dist/modes/interactive/components/keybinding-hints.d.ts +1 -0
- package/dist/modes/interactive/components/keybinding-hints.d.ts.map +1 -1
- package/dist/modes/interactive/components/keybinding-hints.js +7 -1
- package/dist/modes/interactive/components/keybinding-hints.js.map +1 -1
- package/dist/modes/interactive/components/landing-panel.d.ts.map +1 -1
- package/dist/modes/interactive/components/landing-panel.js +15 -2
- package/dist/modes/interactive/components/landing-panel.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +3 -2
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +12 -2
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +3 -0
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +42 -8
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/rpc-entry.js +2492 -1088
- package/dist/utils/hidden-spawn.d.ts +29 -0
- package/dist/utils/hidden-spawn.d.ts.map +1 -0
- package/dist/utils/hidden-spawn.js +101 -0
- package/dist/utils/hidden-spawn.js.map +1 -0
- package/dist/vendor/ai.js +233 -233
- package/dist/vendor/tui.js +1 -1
- package/native/win32/build.mjs +95 -0
- package/native/win32/prebuilds/win32-x64/hidden-spawn.exe +0 -0
- package/native/win32/src/hidden-spawn.c +157 -0
- package/npm-shrinkwrap.json +2 -37
- package/package.json +7 -3
package/dist/vendor/tui.js
CHANGED
|
@@ -8446,7 +8446,7 @@ var Markdown = class {
|
|
|
8446
8446
|
stylePrefix: this.getStylePrefix(headingStyleFn)
|
|
8447
8447
|
};
|
|
8448
8448
|
const headingText = this.renderInlineTokens(token.tokens || [], headingStyleContext);
|
|
8449
|
-
const styledHeading = headingLevel >= 3 ? headingStyleFn(headingPrefix) + headingText : headingText;
|
|
8449
|
+
const styledHeading = headingLevel >= 3 && this.options.showHeadingMarkers !== false ? headingStyleFn(headingPrefix) + headingText : headingText;
|
|
8450
8450
|
lines.push(styledHeading);
|
|
8451
8451
|
if (nextTokenType && nextTokenType !== "space") {
|
|
8452
8452
|
lines.push("");
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { spawnSync } from "node:child_process";
|
|
2
|
+
import { chmodSync, copyFileSync, existsSync, mkdirSync, mkdtempSync, rmSync, writeFileSync } from "node:fs";
|
|
3
|
+
import { tmpdir } from "node:os";
|
|
4
|
+
import * as path from "node:path";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
|
+
|
|
7
|
+
const scriptDir = path.dirname(fileURLToPath(import.meta.url));
|
|
8
|
+
const sourceFile = path.join(scriptDir, "src", "hidden-spawn.c");
|
|
9
|
+
const hostArch = process.arch === "arm64" ? "arm64" : "x64";
|
|
10
|
+
const temporaryDir = mkdtempSync(path.join(tmpdir(), "nexus-hidden-spawn-"));
|
|
11
|
+
|
|
12
|
+
function removeTemporaryDir() {
|
|
13
|
+
rmSync(temporaryDir, { recursive: true, force: true, maxRetries: 5, retryDelay: 100 });
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
process.on("exit", removeTemporaryDir);
|
|
17
|
+
|
|
18
|
+
function quoteBatch(value) {
|
|
19
|
+
return `"${value.replaceAll('"', '""')}"`;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
function findVisualStudioDevCmd() {
|
|
23
|
+
const candidates = [];
|
|
24
|
+
const programFilesX86 = process.env["ProgramFiles(x86)"];
|
|
25
|
+
if (programFilesX86) {
|
|
26
|
+
const vswhere = path.join(programFilesX86, "Microsoft Visual Studio", "Installer", "vswhere.exe");
|
|
27
|
+
if (existsSync(vswhere)) {
|
|
28
|
+
const result = spawnSync(
|
|
29
|
+
vswhere,
|
|
30
|
+
["-latest", "-products", "*", "-requires", "Microsoft.VisualStudio.Component.VC.Tools.x86.x64", "-property", "installationPath"],
|
|
31
|
+
{ encoding: "utf8" },
|
|
32
|
+
);
|
|
33
|
+
for (const line of (result.stdout ?? "").split(/\r?\n/)) {
|
|
34
|
+
const installationPath = line.trim();
|
|
35
|
+
if (installationPath) candidates.push(path.join(installationPath, "Common7", "Tools", "VsDevCmd.bat"));
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
for (const base of [process.env.ProgramFiles, programFilesX86]) {
|
|
40
|
+
if (!base) continue;
|
|
41
|
+
for (const edition of ["BuildTools", "Community", "Professional", "Enterprise"]) {
|
|
42
|
+
candidates.push(path.join(base, "Microsoft Visual Studio", "2022", edition, "Common7", "Tools", "VsDevCmd.bat"));
|
|
43
|
+
candidates.push(path.join(base, "Microsoft Visual Studio", "18", edition, "Common7", "Tools", "VsDevCmd.bat"));
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return candidates.find((candidate) => existsSync(candidate));
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
const vsDevCmd = findVisualStudioDevCmd();
|
|
50
|
+
if (!vsDevCmd) {
|
|
51
|
+
throw new Error("Microsoft C++ Build Tools are required to build hidden-spawn.exe (VsDevCmd.bat not found).");
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
const buildDir = path.join(temporaryDir, "msvc");
|
|
55
|
+
const temporaryOutput = path.join(buildDir, "hidden-spawn.exe");
|
|
56
|
+
mkdirSync(buildDir, { recursive: true });
|
|
57
|
+
const batchFile = path.join(buildDir, "build.cmd");
|
|
58
|
+
const msvcArch = hostArch === "arm64" ? "arm64" : "x64";
|
|
59
|
+
writeFileSync(
|
|
60
|
+
batchFile,
|
|
61
|
+
[
|
|
62
|
+
"@echo off",
|
|
63
|
+
`call ${quoteBatch(vsDevCmd)} -no_logo -arch=${msvcArch} -host_arch=${msvcArch}`,
|
|
64
|
+
"if errorlevel 1 exit /b %errorlevel%",
|
|
65
|
+
[
|
|
66
|
+
"cl",
|
|
67
|
+
"/nologo",
|
|
68
|
+
"/TC",
|
|
69
|
+
"/W4",
|
|
70
|
+
"/O1",
|
|
71
|
+
"/GS-",
|
|
72
|
+
`/Fe:${quoteBatch(temporaryOutput)}`,
|
|
73
|
+
quoteBatch(sourceFile),
|
|
74
|
+
"/link",
|
|
75
|
+
"/SUBSYSTEM:WINDOWS",
|
|
76
|
+
"/ENTRY:entry",
|
|
77
|
+
"/NODEFAULTLIB",
|
|
78
|
+
"kernel32.lib",
|
|
79
|
+
"/OPT:REF",
|
|
80
|
+
"/OPT:ICF",
|
|
81
|
+
].join(" "),
|
|
82
|
+
"if errorlevel 1 exit /b %errorlevel%",
|
|
83
|
+
].join("\r\n"),
|
|
84
|
+
);
|
|
85
|
+
|
|
86
|
+
const result = spawnSync("cmd.exe", ["/d", "/s", "/c", batchFile], { cwd: buildDir, stdio: "inherit" });
|
|
87
|
+
if (result.error) throw result.error;
|
|
88
|
+
if (result.status !== 0) throw new Error(`cl.exe failed with exit code ${result.status ?? 1}`);
|
|
89
|
+
|
|
90
|
+
const outputDir = path.join(scriptDir, "prebuilds", `win32-${hostArch}`);
|
|
91
|
+
mkdirSync(outputDir, { recursive: true });
|
|
92
|
+
const output = path.join(outputDir, "hidden-spawn.exe");
|
|
93
|
+
copyFileSync(temporaryOutput, output);
|
|
94
|
+
chmodSync(output, 0o755);
|
|
95
|
+
console.log(`Built ${output}`);
|
|
Binary file
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Windowless relauncher for Nexus child processes on Windows.
|
|
3
|
+
*
|
|
4
|
+
* Node's windowsHide flag asks libuv to both CREATE_NO_WINDOW and SW_HIDE.
|
|
5
|
+
* SW_HIDE runs after the console window has already been created, so a
|
|
6
|
+
* console-subsystem child (node.exe, nexus.exe) flashes for a frame. This
|
|
7
|
+
* process is itself built as SUBSYSTEM:WINDOWS, so spawning it allocates no
|
|
8
|
+
* console. It then starts the real CLI with CREATE_NO_WINDOW and without
|
|
9
|
+
* STARTF_USESHOWWINDOW, forwarding the stdio handles it was given.
|
|
10
|
+
*
|
|
11
|
+
* No C runtime: the only import is kernel32.
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
#include <windows.h>
|
|
15
|
+
|
|
16
|
+
#define CREATE_NO_WINDOW 0x08000000
|
|
17
|
+
|
|
18
|
+
static void zero_bytes(void *memory, size_t size) {
|
|
19
|
+
unsigned char *bytes = (unsigned char *)memory;
|
|
20
|
+
for (size_t index = 0; index < size; index++) bytes[index] = 0;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/* The compiler emits memset for struct clears. Provide it so /NODEFAULTLIB still links. */
|
|
24
|
+
void *memset(void *destination, int value, size_t count) {
|
|
25
|
+
unsigned char *bytes = (unsigned char *)destination;
|
|
26
|
+
while (count-- > 0) *bytes++ = (unsigned char)value;
|
|
27
|
+
return destination;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
static void *heap_alloc(size_t bytes) {
|
|
31
|
+
return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, bytes);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
static void make_inheritable(HANDLE handle) {
|
|
35
|
+
if (handle != NULL && handle != INVALID_HANDLE_VALUE) {
|
|
36
|
+
SetHandleInformation(handle, HANDLE_FLAG_INHERIT, HANDLE_FLAG_INHERIT);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/* Skip the image name libuv placed at the front of this process's command line. */
|
|
41
|
+
static const wchar_t *skip_argv0(const wchar_t *command) {
|
|
42
|
+
if (*command == L'"') {
|
|
43
|
+
command++;
|
|
44
|
+
while (*command != L'\0' && *command != L'"') command++;
|
|
45
|
+
if (*command == L'"') command++;
|
|
46
|
+
} else {
|
|
47
|
+
while (*command != L'\0' && *command != L' ' && *command != L'\t') command++;
|
|
48
|
+
}
|
|
49
|
+
while (*command == L' ' || *command == L'\t') command++;
|
|
50
|
+
return command;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
static int append_quoted(wchar_t **cursor, wchar_t *end, const wchar_t *value) {
|
|
54
|
+
wchar_t *write = *cursor;
|
|
55
|
+
if (write >= end) return 0;
|
|
56
|
+
*write++ = L'"';
|
|
57
|
+
while (*value != L'\0') {
|
|
58
|
+
if (write >= end - 1) return 0;
|
|
59
|
+
*write++ = *value++;
|
|
60
|
+
}
|
|
61
|
+
if (write >= end) return 0;
|
|
62
|
+
*write++ = L'"';
|
|
63
|
+
*cursor = write;
|
|
64
|
+
return 1;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
static int append_raw(wchar_t **cursor, wchar_t *end, const wchar_t *value) {
|
|
68
|
+
wchar_t *write = *cursor;
|
|
69
|
+
while (*value != L'\0') {
|
|
70
|
+
if (write >= end) return 0;
|
|
71
|
+
*write++ = *value++;
|
|
72
|
+
}
|
|
73
|
+
*cursor = write;
|
|
74
|
+
return 1;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
static DWORD read_env(const wchar_t *name, wchar_t *buffer, DWORD capacity) {
|
|
78
|
+
DWORD length = GetEnvironmentVariableW(name, buffer, capacity);
|
|
79
|
+
if (length == 0 || length >= capacity) return 0;
|
|
80
|
+
return length;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
static DWORD run(void) {
|
|
84
|
+
wchar_t *target;
|
|
85
|
+
wchar_t *script;
|
|
86
|
+
wchar_t *command_line;
|
|
87
|
+
const wchar_t *tail;
|
|
88
|
+
wchar_t *cursor;
|
|
89
|
+
wchar_t *end;
|
|
90
|
+
STARTUPINFOW startup;
|
|
91
|
+
PROCESS_INFORMATION process;
|
|
92
|
+
HANDLE job;
|
|
93
|
+
JOBOBJECT_EXTENDED_LIMIT_INFORMATION limits;
|
|
94
|
+
DWORD flags;
|
|
95
|
+
DWORD exit_code = 1;
|
|
96
|
+
int have_script;
|
|
97
|
+
|
|
98
|
+
target = (wchar_t *)heap_alloc(32768 * sizeof(wchar_t));
|
|
99
|
+
script = (wchar_t *)heap_alloc(32768 * sizeof(wchar_t));
|
|
100
|
+
command_line = (wchar_t *)heap_alloc(32768 * sizeof(wchar_t));
|
|
101
|
+
if (target == NULL || script == NULL || command_line == NULL) return 1;
|
|
102
|
+
|
|
103
|
+
if (read_env(L"NEXUS_HIDDEN_SPAWN_TARGET", target, 32768) == 0) return 1;
|
|
104
|
+
have_script = read_env(L"NEXUS_HIDDEN_SPAWN_SCRIPT", script, 32768) != 0;
|
|
105
|
+
tail = skip_argv0(GetCommandLineW());
|
|
106
|
+
|
|
107
|
+
cursor = command_line;
|
|
108
|
+
end = command_line + 32767;
|
|
109
|
+
if (!append_quoted(&cursor, end, target)) return 1;
|
|
110
|
+
if (have_script) {
|
|
111
|
+
if (!append_raw(&cursor, end, L" ")) return 1;
|
|
112
|
+
if (!append_quoted(&cursor, end, script)) return 1;
|
|
113
|
+
}
|
|
114
|
+
if (*tail != L'\0') {
|
|
115
|
+
if (!append_raw(&cursor, end, L" ")) return 1;
|
|
116
|
+
if (!append_raw(&cursor, end, tail)) return 1;
|
|
117
|
+
}
|
|
118
|
+
if (cursor >= end) return 1;
|
|
119
|
+
*cursor = L'\0';
|
|
120
|
+
|
|
121
|
+
zero_bytes(&startup, sizeof startup);
|
|
122
|
+
startup.cb = sizeof startup;
|
|
123
|
+
startup.dwFlags = STARTF_USESTDHANDLES;
|
|
124
|
+
startup.hStdInput = GetStdHandle(STD_INPUT_HANDLE);
|
|
125
|
+
startup.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE);
|
|
126
|
+
startup.hStdError = GetStdHandle(STD_ERROR_HANDLE);
|
|
127
|
+
make_inheritable(startup.hStdInput);
|
|
128
|
+
make_inheritable(startup.hStdOutput);
|
|
129
|
+
make_inheritable(startup.hStdError);
|
|
130
|
+
|
|
131
|
+
zero_bytes(&process, sizeof process);
|
|
132
|
+
flags = CREATE_NO_WINDOW | CREATE_UNICODE_ENVIRONMENT | CREATE_SUSPENDED;
|
|
133
|
+
if (!CreateProcessW(target, command_line, NULL, NULL, TRUE, flags, NULL, NULL, &startup, &process)) {
|
|
134
|
+
return 1;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
job = CreateJobObjectW(NULL, NULL);
|
|
138
|
+
if (job != NULL) {
|
|
139
|
+
zero_bytes(&limits, sizeof limits);
|
|
140
|
+
limits.BasicLimitInformation.LimitFlags = JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE;
|
|
141
|
+
if (SetInformationJobObject(job, JobObjectExtendedLimitInformation, &limits, sizeof limits)) {
|
|
142
|
+
AssignProcessToJobObject(job, process.hProcess);
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
ResumeThread(process.hThread);
|
|
147
|
+
WaitForSingleObject(process.hProcess, INFINITE);
|
|
148
|
+
if (!GetExitCodeProcess(process.hProcess, &exit_code)) exit_code = 1;
|
|
149
|
+
CloseHandle(process.hThread);
|
|
150
|
+
CloseHandle(process.hProcess);
|
|
151
|
+
if (job != NULL) CloseHandle(job);
|
|
152
|
+
return exit_code;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
void entry(void) {
|
|
156
|
+
ExitProcess(run());
|
|
157
|
+
}
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akon-labs/nexus-cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.11",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@akon-labs/nexus-cli",
|
|
9
|
-
"version": "0.1.
|
|
9
|
+
"version": "0.1.11",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@anthropic-ai/sdk": "0.91.1",
|
|
@@ -879,9 +879,6 @@
|
|
|
879
879
|
"cpu": [
|
|
880
880
|
"arm64"
|
|
881
881
|
],
|
|
882
|
-
"libc": [
|
|
883
|
-
"glibc"
|
|
884
|
-
],
|
|
885
882
|
"optional": true
|
|
886
883
|
},
|
|
887
884
|
"node_modules/@napi-rs/keyring-linux-arm64-musl": {
|
|
@@ -898,9 +895,6 @@
|
|
|
898
895
|
"cpu": [
|
|
899
896
|
"arm64"
|
|
900
897
|
],
|
|
901
|
-
"libc": [
|
|
902
|
-
"musl"
|
|
903
|
-
],
|
|
904
898
|
"optional": true
|
|
905
899
|
},
|
|
906
900
|
"node_modules/@napi-rs/keyring-linux-riscv64-gnu": {
|
|
@@ -917,9 +911,6 @@
|
|
|
917
911
|
"cpu": [
|
|
918
912
|
"riscv64"
|
|
919
913
|
],
|
|
920
|
-
"libc": [
|
|
921
|
-
"glibc"
|
|
922
|
-
],
|
|
923
914
|
"optional": true
|
|
924
915
|
},
|
|
925
916
|
"node_modules/@napi-rs/keyring-linux-x64-gnu": {
|
|
@@ -936,9 +927,6 @@
|
|
|
936
927
|
"cpu": [
|
|
937
928
|
"x64"
|
|
938
929
|
],
|
|
939
|
-
"libc": [
|
|
940
|
-
"glibc"
|
|
941
|
-
],
|
|
942
930
|
"optional": true
|
|
943
931
|
},
|
|
944
932
|
"node_modules/@napi-rs/keyring-linux-x64-musl": {
|
|
@@ -955,9 +943,6 @@
|
|
|
955
943
|
"cpu": [
|
|
956
944
|
"x64"
|
|
957
945
|
],
|
|
958
|
-
"libc": [
|
|
959
|
-
"musl"
|
|
960
|
-
],
|
|
961
946
|
"optional": true
|
|
962
947
|
},
|
|
963
948
|
"node_modules/@napi-rs/keyring-win32-arm64-msvc": {
|
|
@@ -2089,26 +2074,6 @@
|
|
|
2089
2074
|
"typebox": "1.1.38",
|
|
2090
2075
|
"yaml": "2.8.3"
|
|
2091
2076
|
},
|
|
2092
|
-
"peerDependencies": {
|
|
2093
|
-
"@earendil-works/pi-agent-core": "*",
|
|
2094
|
-
"@earendil-works/pi-ai": ">=0.80.0",
|
|
2095
|
-
"@earendil-works/pi-coding-agent": "*",
|
|
2096
|
-
"@earendil-works/pi-tui": "*"
|
|
2097
|
-
},
|
|
2098
|
-
"peerDependenciesMeta": {
|
|
2099
|
-
"@earendil-works/pi-agent-core": {
|
|
2100
|
-
"optional": true
|
|
2101
|
-
},
|
|
2102
|
-
"@earendil-works/pi-ai": {
|
|
2103
|
-
"optional": true
|
|
2104
|
-
},
|
|
2105
|
-
"@earendil-works/pi-coding-agent": {
|
|
2106
|
-
"optional": true
|
|
2107
|
-
},
|
|
2108
|
-
"@earendil-works/pi-tui": {
|
|
2109
|
-
"optional": true
|
|
2110
|
-
}
|
|
2111
|
-
},
|
|
2112
2077
|
"bin": {
|
|
2113
2078
|
"pi-subagents": "install.mjs"
|
|
2114
2079
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akon-labs/nexus-cli",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.1.11",
|
|
4
|
+
"description": "NexusAgent coding CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"piConfig": {
|
|
7
7
|
"name": "nexus",
|
|
@@ -38,6 +38,9 @@
|
|
|
38
38
|
"dist",
|
|
39
39
|
"docs",
|
|
40
40
|
"examples",
|
|
41
|
+
"native/win32/src",
|
|
42
|
+
"native/win32/prebuilds",
|
|
43
|
+
"native/win32/build.mjs",
|
|
41
44
|
"containerization.md",
|
|
42
45
|
"CHANGELOG.md",
|
|
43
46
|
"npm-shrinkwrap.json",
|
|
@@ -48,7 +51,7 @@
|
|
|
48
51
|
"build": "tsgo -p tsconfig.build.json && shx chmod +x dist/cli.js dist/rpc-entry.js && npm run copy-assets && shx mkdir -p dist/extensions/gitnexus/skills && shx cp -r src/extensions/gitnexus/skills/* dist/extensions/gitnexus/skills/ && npm run bundle",
|
|
49
52
|
"build:binary": "npm --prefix ../tui run build && npm --prefix ../ai run build && npm --prefix ../agent run build && npm --prefix ../protocol run build && npm --prefix ../client run build && npm run build && bun build --compile ./dist/bun/cli.js ./src/utils/image-resize-worker.ts ./src/extensions/mcp/mcp-script-worker.mjs --outfile dist/pi && npm run copy-binary-assets",
|
|
50
53
|
"copy-assets": "shx mkdir -p dist/modes/interactive/theme && shx cp src/modes/interactive/theme/*.json dist/modes/interactive/theme/ && shx mkdir -p dist/core/export-html/vendor && shx cp src/core/export-html/template.html src/core/export-html/template.css src/core/export-html/template.js dist/core/export-html/ && shx cp src/core/export-html/vendor/*.js dist/core/export-html/vendor/ && shx mkdir -p dist/extensions/mcp/skills dist/skills && shx cp src/extensions/mcp/app-bridge.bundle.js src/extensions/mcp/mcp-script-worker.mjs src/extensions/mcp/mcp-keyring-helper.cjs dist/ && shx cp src/extensions/mcp/app-bridge.bundle.js src/extensions/mcp/mcp-script-worker.mjs src/extensions/mcp/mcp-keyring-helper.cjs dist/extensions/mcp/ && shx cp -r src/extensions/mcp/skills/* dist/extensions/mcp/skills/ && shx cp -r src/extensions/mcp/skills/* dist/skills/",
|
|
51
|
-
"copy-binary-assets": "shx cp package.json dist/ && shx cp README.md dist/ && shx cp CHANGELOG.md dist/ && shx mkdir -p dist/theme && shx cp src/modes/interactive/theme/*.json dist/theme/ && shx mkdir -p dist/export-html/vendor && shx cp src/core/export-html/template.html dist/export-html/ && shx cp src/core/export-html/vendor/*.js dist/export-html/vendor/ && shx cp -r docs dist/ && shx cp -r examples dist/ && shx cp ../../node_modules/@silvia-odwyer/photon-node/photon_rs_bg.wasm dist/",
|
|
54
|
+
"copy-binary-assets": "shx cp package.json dist/ && shx cp README.md dist/ && shx cp CHANGELOG.md dist/ && shx mkdir -p dist/theme && shx cp src/modes/interactive/theme/*.json dist/theme/ && shx mkdir -p dist/export-html/vendor && shx cp src/core/export-html/template.html dist/export-html/ && shx cp src/core/export-html/vendor/*.js dist/export-html/vendor/ && shx cp -r docs dist/ && shx cp -r examples dist/ && shx cp ../../node_modules/@silvia-odwyer/photon-node/photon_rs_bg.wasm dist/ && node native/win32/copy-beside-binary.mjs",
|
|
52
55
|
"test": "vitest --run",
|
|
53
56
|
"shrinkwrap": "node ../../scripts/generate-coding-agent-shrinkwrap.mjs",
|
|
54
57
|
"prepublishOnly": "npm run clean && npm run build && npm run shrinkwrap",
|
|
@@ -139,3 +142,4 @@
|
|
|
139
142
|
"access": "public"
|
|
140
143
|
}
|
|
141
144
|
}
|
|
145
|
+
|