diff options
Diffstat (limited to 'packages/tui/internal/commands')
| -rw-r--r-- | packages/tui/internal/commands/command.go | 10 |
1 files changed, 9 insertions, 1 deletions
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" @@ -249,6 +251,12 @@ func LoadFromConfig(config *opencode.Config) CommandRegistry { Trigger: []string{"models"}, }, { + Name: AgentListCommand, + Description: "list agents", + Keybindings: parseBindings("<leader>a"), + Trigger: []string{"agents"}, + }, + { Name: ThemeListCommand, Description: "list themes", Keybindings: parseBindings("<leader>t"), |
