From 62b8c7aee0cb4da28b3dbb99ed1aed4be4360127 Mon Sep 17 00:00:00 2001 From: Aiden Cline <63023139+rekram1-node@users.noreply.github.com> Date: Mon, 11 Aug 2025 00:46:38 -0500 Subject: feat (tui): agents dialog (#1802) --- packages/tui/internal/commands/command.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'packages/tui/internal/commands') diff --git a/packages/tui/internal/commands/command.go b/packages/tui/internal/commands/command.go index cb54bd09d..55f118aaa 100644 --- a/packages/tui/internal/commands/command.go +++ b/packages/tui/internal/commands/command.go @@ -64,12 +64,13 @@ func (r CommandRegistry) Sorted() []Command { commands = append(commands, command) } slices.SortFunc(commands, func(a, b Command) int { - // Priority order: session_new, session_share, model_list, app_help first, app_exit last + // Priority order: session_new, session_share, model_list, agent_list, app_help first, app_exit last priorityOrder := map[CommandName]int{ SessionNewCommand: 0, AppHelpCommand: 1, SessionShareCommand: 2, ModelListCommand: 3, + AgentListCommand: 4, } aPriority, aHasPriority := priorityOrder[a.Name] @@ -119,6 +120,7 @@ const ( SessionExportCommand CommandName = "session_export" ToolDetailsCommand CommandName = "tool_details" ModelListCommand CommandName = "model_list" + AgentListCommand CommandName = "agent_list" ThemeListCommand CommandName = "theme_list" FileListCommand CommandName = "file_list" FileCloseCommand CommandName = "file_close" @@ -248,6 +250,12 @@ func LoadFromConfig(config *opencode.Config) CommandRegistry { Keybindings: parseBindings("m"), Trigger: []string{"models"}, }, + { + Name: AgentListCommand, + Description: "list agents", + Keybindings: parseBindings("a"), + Trigger: []string{"agents"}, + }, { Name: ThemeListCommand, Description: "list themes", -- cgit v1.2.3