refactor: Migrate from prettytable to comfy-table for output formatting
Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) <aider@aider.chat>
This commit is contained in:
@@ -142,16 +142,16 @@ fn build_compression_table(compression_info: &Vec<CompressionInfo>) -> Table {
|
||||
compression_table.add_row(vec![
|
||||
info.compression_type.clone(),
|
||||
match info.found {
|
||||
true => Cell::new("Yes").fg(Color::Green),
|
||||
false => Cell::new("No").fg(Color::Red),
|
||||
true => Cell::new("Yes").fg(Color::Green).to_string(),
|
||||
false => Cell::new("No").fg(Color::Red).to_string(),
|
||||
},
|
||||
match info.default {
|
||||
true => Cell::new("Yes").fg(Color::Green),
|
||||
false => Cell::new("No"),
|
||||
true => Cell::new("Yes").fg(Color::Green).to_string(),
|
||||
false => Cell::new("No").to_string(),
|
||||
},
|
||||
match info.binary.as_str() {
|
||||
"<INTERNAL>" => Cell::new(&info.binary).fg(Color::DarkGrey),
|
||||
_ => Cell::new(&info.binary),
|
||||
"<INTERNAL>" => Cell::new(&info.binary).fg(Color::DarkGrey).to_string(),
|
||||
_ => info.binary.clone(),
|
||||
},
|
||||
info.compress.clone(),
|
||||
info.decompress.clone(),
|
||||
@@ -287,15 +287,16 @@ pub fn mode_status_plugins(
|
||||
match output_format {
|
||||
OutputFormat::Table => {
|
||||
println!("META PLUGINS:");
|
||||
build_meta_plugin_table(&status_info.meta_plugins).printstd();
|
||||
println!("META PLUGINS:");
|
||||
println!("{}", build_meta_plugin_table(&status_info.meta_plugins));
|
||||
println!();
|
||||
|
||||
println!("COMPRESSION PLUGINS:");
|
||||
build_compression_table(&status_info.compression).printstd();
|
||||
println!("{}", build_compression_table(&status_info.compression));
|
||||
println!();
|
||||
|
||||
println!("FILTER PLUGINS:");
|
||||
build_filter_plugin_table(&status_info.filter_plugins).printstd();
|
||||
println!("{}", build_filter_plugin_table(&status_info.filter_plugins));
|
||||
println!();
|
||||
Ok(())
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user