On Mon, Jun 03, 2024 at 03:52:54PM +0200, Franco Martelli wrote: > > > > > > ~$ tree --du -Fah /tmp/x | grep --color /$ > > You're only coloring the trailing / characters. If you want everything > > from after the last space to the end of the line, you'd want: > > > > tree --du -Fh /usr/local | grep --color '[^[:space:]]*/$' > > I realized why "tree" command doesn't colorized the directories: "tree" > detects that its std output goes through a pipe and therefore it disables > the escaped code to colorize (like also "dmesg" does).
That's what the "-C" option to tree is for. Cheers -- "if everything else fails, read the man page" tomas
signature.asc
Description: PGP signature