feat: sort meta plugins by name in status tables
Co-authored-by: aider (openai/andrew/openrouter/mistralai/mistral-medium-3.1) <aider@aider.chat>
This commit is contained in:
@@ -134,6 +134,10 @@ fn build_meta_plugins_configured_table(settings: &config::Settings) -> Option<Ta
|
||||
return None;
|
||||
}
|
||||
|
||||
// Sort meta plugins by name
|
||||
let mut sorted_meta_plugins = meta_plugins.clone();
|
||||
sorted_meta_plugins.sort_by(|a, b| a.name.cmp(&b.name));
|
||||
|
||||
let mut table = Table::new();
|
||||
if std::io::stdout().is_terminal() {
|
||||
//table.set_format(get_format_box_chars_no_border_line_separator());
|
||||
@@ -148,7 +152,7 @@ fn build_meta_plugins_configured_table(settings: &config::Settings) -> Option<Ta
|
||||
Cell::new("Outputs").with_style(Attr::Bold),
|
||||
]));
|
||||
|
||||
for plugin_config in meta_plugins {
|
||||
for plugin_config in sorted_meta_plugins {
|
||||
// Create the plugin to get its default options
|
||||
let meta_plugin_type = match MetaPluginType::from_str(&plugin_config.name) {
|
||||
Ok(plugin_type) => plugin_type,
|
||||
@@ -282,7 +286,11 @@ fn build_meta_plugin_table(meta_plugin_info: &Vec<MetaPluginInfo>) -> Table {
|
||||
b->"Options",
|
||||
b->"Outputs"));
|
||||
|
||||
for info in meta_plugin_info {
|
||||
// Sort meta plugin info by plugin name
|
||||
let mut sorted_meta_plugin_info = meta_plugin_info.clone();
|
||||
sorted_meta_plugin_info.sort_by(|a, b| a.meta_name.cmp(&b.meta_name));
|
||||
|
||||
for info in sorted_meta_plugin_info {
|
||||
// Get default options for the meta plugin
|
||||
let meta_plugin_type = match MetaPluginType::from_str(&info.meta_name) {
|
||||
Ok(plugin_type) => plugin_type,
|
||||
|
||||
Reference in New Issue
Block a user