From 403ffd3814f800e47604210ac080bfb1d4d0c63e Mon Sep 17 00:00:00 2001 From: Colin Walters Date: Fri, 6 Dec 2024 14:25:12 -0500 Subject: [PATCH] tree-wide: Call `set_content_arrangement` for tables Let's wrap by default. Signed-off-by: Colin Walters --- lib/src/image.rs | 1 + ostree-ext/src/cli.rs | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/src/image.rs b/lib/src/image.rs index f6e5303f6..4d0b8a04d 100644 --- a/lib/src/image.rs +++ b/lib/src/image.rs @@ -105,6 +105,7 @@ pub(crate) async fn list_entrypoint( table .load_preset(NOTHING) + .set_content_arrangement(comfy_table::ContentArrangement::Dynamic) .set_header(vec!["REPOSITORY", "TYPE"]); for image in images { diff --git a/ostree-ext/src/cli.rs b/ostree-ext/src/cli.rs index 53fa15148..fa60ccf41 100644 --- a/ostree-ext/src/cli.rs +++ b/ostree-ext/src/cli.rs @@ -906,7 +906,8 @@ async fn container_history(repo: &ostree::Repo, imgref: &ImageReference) -> Resu let mut table = comfy_table::Table::new(); table .load_preset(comfy_table::presets::NOTHING) - .set_header(["ID", "SIZE", "CREATED BY"]); + .set_content_arrangement(comfy_table::ContentArrangement::Dynamic) + .set_header(["ID", "SIZE", "CRCEATED BY"]); let mut history = img.configuration.history().iter(); let layers = img.manifest.layers().iter();