lsd icon indicating copy to clipboard operation
lsd copied to clipboard

[Feature]: add an option to turn of --classify

Open meatcar opened this issue 2 years ago • 2 comments

Version

  • [X] latest

version

lsd 1.0.0

What OS are you seeing the problem on?

Linux

installation

NixOS

term

No response

ls-colors

No response

What happened?

I have lsd configured with indicators = true. The indicators persist when lsd is used non-interactively, i.e it's output is piped.

$ mkdir -p test; cd test
$ touch foo; chmod +x foo
$ lsd | xargs rm
rm: cannot remove 'foo*': No such file or directory
$ lsd
  foo*

There should be no files remaining. Instead, foo was never removed.

What expected?

We should be able to run lsd --classify --indicator-style=none and the two options would cancel each other out, showing no suffixes for special files. This would mirror the option in ls, the recommended way to turn off --classify according to https://superuser.com/a/220680

In general, each configurable setting that can be turned on with an option should have an option to turn it off.

What else?

Another potential approach is to hide the classifiers when stdout is not a tty, maybe configurable by a setting? A downside is compatibility with ls would break.

meatcar avatar Sep 28 '23 22:09 meatcar

I faced this problem today as of lsd 1.1.2. It seems there's work to do regarding indicators consistency... Given that when long listing the setting is not respected.

bryanjhv avatar Apr 09 '24 15:04 bryanjhv

/kind feature

adding --indicator-style=none

zwpaper avatar Apr 29 '24 08:04 zwpaper