From fba7c73c8b56f41c31731dae9f94f4dea6cdf466 Mon Sep 17 00:00:00 2001 From: Mohamed Boudra Date: Thu, 12 Feb 2026 14:15:33 +0700 Subject: [PATCH] feat(cli): add agent update command for name and labels --- packages/cli/src/cli.ts | 16 ++ packages/cli/src/commands/agent/index.ts | 16 ++ packages/cli/src/commands/agent/update.ts | 177 ++++++++++++++++++ packages/cli/tests/16-agent-update.test.ts | 132 +++++++++++++ packages/server/src/client/daemon-client.ts | 34 ++++ .../server/src/server/agent/agent-manager.ts | 10 + packages/server/src/server/session.ts | 91 +++++++++ packages/server/src/shared/messages.ts | 22 +++ 8 files changed, 498 insertions(+) create mode 100644 packages/cli/src/commands/agent/update.ts create mode 100644 packages/cli/tests/16-agent-update.test.ts diff --git a/packages/cli/src/cli.ts b/packages/cli/src/cli.ts index 928b32c9e..e7e726203 100644 --- a/packages/cli/src/cli.ts +++ b/packages/cli/src/cli.ts @@ -16,6 +16,7 @@ import { runSendCommand } from './commands/agent/send.js' import { runInspectCommand } from './commands/agent/inspect.js' import { runWaitCommand } from './commands/agent/wait.js' import { runAttachCommand } from './commands/agent/attach.js' +import { runUpdateCommand } from './commands/agent/update.js' import { withOutput } from './output/index.js' const VERSION = '0.1.0' @@ -125,6 +126,21 @@ export function createCli(): Command { .option('--host ', 'Daemon host:port (default: localhost:6767)') .action(withOutput(runWaitCommand)) + program + .command('update') + .description('Update an agent (alias for "paseo agent update")') + .argument('', 'Agent ID (or prefix)') + .option('--name ', "Update the agent's display name") + .option( + '--label