Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
116111c
refactor(cli): harden oclif bridge
cv Apr 30, 2026
5e997cb
test(cli): relax uninstall helper timeouts
cv Apr 30, 2026
88cd958
refactor(cli): migrate status and tunnel commands to oclif
cv Apr 30, 2026
3f748d6
refactor(cli): migrate debug uninstall and gateway-token to oclif
cv Apr 30, 2026
0bc877a
refactor(cli): migrate credentials commands to oclif
cv Apr 30, 2026
3fd15fc
refactor(cli): migrate sandbox inspection commands to oclif
cv Apr 30, 2026
81c62bb
refactor(cli): migrate maintenance commands to oclif
cv Apr 30, 2026
7d6a6fb
refactor(cli): migrate sandbox logs command to oclif
cv May 1, 2026
3f17a4f
refactor(cli): migrate skill install command to oclif
cv May 1, 2026
0fb3c41
refactor(cli): migrate snapshot list and create to oclif
cv May 1, 2026
d11eeee
refactor(cli): migrate shields commands to oclif
cv May 1, 2026
74806ce
refactor(cli): migrate channels mutation commands to oclif
cv May 1, 2026
e637e84
refactor(cli): migrate policy mutation commands to oclif
cv May 1, 2026
ee20dfb
refactor(cli): migrate snapshot restore command to oclif
cv May 1, 2026
8d3a568
refactor(cli): migrate destroy command to oclif
cv May 1, 2026
b447f36
refactor(cli): migrate rebuild command to oclif
cv May 1, 2026
02431db
refactor(cli): migrate connect command to oclif
cv May 1, 2026
37ce2ff
refactor(cli): migrate deploy command to oclif
cv May 1, 2026
d3e218e
refactor(cli): migrate onboard aliases to oclif
cv May 1, 2026
df05a3e
refactor(cli): migrate help and version commands to oclif
cv May 1, 2026
3edcf2e
refactor(cli): centralize legacy oclif dispatch
cv May 1, 2026
47df3b5
refactor(cli): drop trivial oclif wrapper helpers
cv May 1, 2026
460173c
refactor(cli): centralize sandbox runtime bridge
cv May 1, 2026
31c0195
test(cli): keep dispatch table out of coverage ratchet
cv May 1, 2026
bad424d
refactor(cli): centralize policy and channels runtime bridge
cv May 1, 2026
5214142
refactor(cli): centralize global runtime bridge
cv May 1, 2026
5fca48f
refactor(cli): collapse runtime bridge exports
cv May 1, 2026
9616295
refactor(cli): introduce sandbox runtime action facade
cv May 1, 2026
c3a4906
refactor(cli): introduce policy and channels action facade
cv May 1, 2026
35288d8
refactor(cli): introduce global command action facade
cv May 1, 2026
58e71de
refactor(cli): extract root help action
cv May 1, 2026
66a1673
refactor(cli): extract deploy action
cv May 1, 2026
e60ba8e
refactor(cli): extract onboard actions
cv May 1, 2026
39cf641
merge(main): resolve onboard action conflicts
cv May 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions src/lib/global-cli-actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,24 @@
/* v8 ignore start -- transitional action facade until implementations leave src/nemoclaw.ts. */

import { runDeployAction as executeDeployAction } from "./deploy-action";
import {
runOnboardAction as executeOnboardAction,
runSetupAction as executeSetupAction,
runSetupSparkAction as executeSetupSparkAction,
} from "./onboard-action";
import { getNemoClawRuntimeBridge } from "./nemoclaw-runtime-bridge";
import { help, version } from "./root-help-action";

export async function runOnboardAction(args: string[] = []): Promise<void> {
await getNemoClawRuntimeBridge().onboard(args);
await executeOnboardAction(args);
}

export async function runSetupAction(args: string[] = []): Promise<void> {
await getNemoClawRuntimeBridge().setup(args);
await executeSetupAction(args);
}

export async function runSetupSparkAction(args: string[] = []): Promise<void> {
await getNemoClawRuntimeBridge().setupSpark(args);
await executeSetupSparkAction(args);
}

export async function runDeployAction(instanceName?: string): Promise<void> {
Expand Down
3 changes: 0 additions & 3 deletions src/lib/nemoclaw-runtime-bridge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export interface NemoClawRuntimeBridge {
) => { status: number | null; output: string };
backupAll: () => void;
garbageCollectImages: (args?: string[]) => Promise<void>;
onboard: (args?: string[]) => Promise<void>;
recoverNamedGatewayRuntime: () => Promise<GatewayRecoveryResult>;
recoverRegistryEntries: (options?: {
requestedSandboxName?: string | null;
Expand Down Expand Up @@ -55,8 +54,6 @@ export interface NemoClawRuntimeBridge {
sandboxSkillInstall: (sandboxName: string, args?: string[]) => Promise<void>;
sandboxSnapshot: (sandboxName: string, subArgs: string[]) => Promise<void>;
sandboxStatus: (sandboxName: string) => Promise<void>;
setup: (args?: string[]) => Promise<void>;
setupSpark: (args?: string[]) => Promise<void>;
upgradeSandboxes: (args?: string[]) => Promise<void>;
}

Expand Down
42 changes: 42 additions & 0 deletions src/lib/onboard-action.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-License-Identifier: Apache-2.0

import { listAgents } from "./agent-defs";
import { runDeprecatedOnboardAliasCommand, runOnboardCommand } from "./onboard-command";
import { NOTICE_ACCEPT_ENV, NOTICE_ACCEPT_FLAG } from "./usage-notice";

const { onboard: runOnboard } = require("./onboard") as {
onboard: (options?: unknown) => Promise<void>;
};

function buildOnboardCommandDeps(args: string[]) {
return {
args,
noticeAcceptFlag: NOTICE_ACCEPT_FLAG,
noticeAcceptEnv: NOTICE_ACCEPT_ENV,
env: process.env,
runOnboard,
listAgents,
log: console.log,
error: console.error,
exit: (code: number) => process.exit(code),
};
}

export async function runOnboardAction(args: string[]): Promise<void> {
await runOnboardCommand(buildOnboardCommandDeps(args));
}

export async function runSetupAction(args: string[] = []): Promise<void> {
await runDeprecatedOnboardAliasCommand({
...buildOnboardCommandDeps(args),
kind: "setup",
});
}

export async function runSetupSparkAction(args: string[] = []): Promise<void> {
await runDeprecatedOnboardAliasCommand({
...buildOnboardCommandDeps(args),
kind: "setup-spark",
});
}
39 changes: 0 additions & 39 deletions src/nemoclaw.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ const { help, version } = require("./lib/root-help-action");
const onboardSession = require("./lib/onboard-session");
import type { Session } from "./lib/onboard-session";
const { parseLiveSandboxNames } = require("./lib/runtime-recovery");
const { NOTICE_ACCEPT_ENV, NOTICE_ACCEPT_FLAG } = require("./lib/usage-notice");
const { runDeprecatedOnboardAliasCommand, runOnboardCommand } = require("./lib/onboard-command");
const {
captureOpenshellCommandAsync,
captureOpenshellCommand,
Expand Down Expand Up @@ -701,7 +699,6 @@ exports.runtimeBridge = {
captureOpenshell,
backupAll,
garbageCollectImages,
onboard,
recoverNamedGatewayRuntime,
recoverRegistryEntries,
runOpenshell,
Expand All @@ -720,8 +717,6 @@ exports.runtimeBridge = {
sandboxSkillInstall,
sandboxSnapshot,
sandboxStatus,
setup,
setupSpark,
upgradeSandboxes,
};
exports.ensureLiveSandboxOrExit = ensureLiveSandboxOrExit;
Expand Down Expand Up @@ -1272,40 +1267,6 @@ function exitWithSpawnResult(result: SpawnLikeResult & { signal?: NodeJS.Signals

// ── Commands ─────────────────────────────────────────────────────

function buildOnboardCommandDeps(args: string[]) {
const { onboard: runOnboard } = require("./lib/onboard");
const { listAgents } = require("./lib/agent-defs");
return {
args,
noticeAcceptFlag: NOTICE_ACCEPT_FLAG,
noticeAcceptEnv: NOTICE_ACCEPT_ENV,
env: process.env,
runOnboard,
listAgents,
log: console.log,
error: console.error,
exit: (code: number) => process.exit(code),
};
}

async function onboard(args: string[]): Promise<void> {
await runOnboardCommand(buildOnboardCommandDeps(args));
}

async function setup(args: string[] = []): Promise<void> {
await runDeprecatedOnboardAliasCommand({
...buildOnboardCommandDeps(args),
kind: "setup",
});
}

async function setupSpark(args: string[] = []): Promise<void> {
await runDeprecatedOnboardAliasCommand({
...buildOnboardCommandDeps(args),
kind: "setup-spark",
});
}

async function runOclif(commandId: string, args: string[] = []): Promise<void> {
await runRegisteredOclifCommand(commandId, args, {
rootDir: ROOT,
Expand Down
Loading