From 3dab2b739072efec893bbf50445a8529db55d78d Mon Sep 17 00:00:00 2001 From: Daniel Hofstetter Date: Mon, 11 Dec 2023 09:33:36 +0100 Subject: [PATCH] ls: use show_dir_name to output dir name --- src/uu/ls/src/ls.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/uu/ls/src/ls.rs b/src/uu/ls/src/ls.rs index 3b34cf15e..a5fe3d624 100644 --- a/src/uu/ls/src/ls.rs +++ b/src/uu/ls/src/ls.rs @@ -1961,7 +1961,8 @@ pub fn list(locs: Vec<&Path>, config: &Config) -> UResult<()> { if config.dired { dired::indent(&mut out)?; } - writeln!(out, "{}:", path_data.p_buf.display())?; + show_dir_name(&path_data.p_buf, &mut out); + writeln!(out)?; if config.dired { // First directory displayed let dir_len = path_data.display_name.len();