Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 14 additions & 3 deletions module/core/format_tools/src/format/output_format/table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,20 @@ impl TableOutputFormat for Table

write!( c.buf, "{}", cell_prefix )?;

// println!( "icol : {icol} | irow : {irow} | width : {width} | cell_width : {cell_width}" );
let lspaces = ( width - cell_width ) / 2;
let rspaces = ( width - cell_width + 1 ) / 2 + cell_width - slice.len();
println!( "icol : {icol} | irow : {irow} | width : {width} | cell_width : {cell_width} | slice.len() : {}", slice.len() );

let lspaces = if cell_width > width {
0
} else {
( width - cell_width ) / 2
};

let rspaces = if (cell_width > width) || (slice.len() > cell_width) {
0
} else {
( width - cell_width + 1 ) / 2 + cell_width - slice.len()
};

// println!( "icol : {icol} | irow : {irow} | width : {width} | cell_width : {cell_width} | lspaces : {lspaces} | rspaces : {rspaces}" );

if lspaces > 0
Expand Down
2 changes: 1 addition & 1 deletion module/move/assistant/src/bin/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use clap::Parser;

use assistant::
{
client,
client::client,
commands::{ Cli, CliCommand, self },
Secret
};
Expand Down
Loading