Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option --icon with absent mode argument should be equivalent to --icon always #956

Open
turbocrime opened this issue Nov 18, 2023 · 0 comments

Comments

@turbocrime
Copy link

existing behavior

the --icon option requires an argument

~ $ lsd --icon
error: a value is required for '--icon <MODE>' but none was supplied
  [possible values: always, auto, never]
~ $ 

expected behavior

the --icon option with no argument should enable icons

~ $ lsd --icon
📂 Desktop  📂 Developer  📂 Documents  📂 Downloads  📂 Library  📂 Movies  📂 Music  📂 Pictures  📂 Public
~ $

details

it is reasonable to assume that manual application of an --icon option with no arguments intends --icon always

in my ~/.config/lsd/config.yml i have

icons:
  when: never
  theme: unicode

i have many short aliases defined in my .zshrc for various modes and behaviors, none of them involving icons.

occasionally, i might want to display icons. it would be nice to simply run lsd --icon (or any of my aliases, with an icon option) to activate icon display.

i understand this feature might have been deliberately avoided due to the possibility for accidental application of following file name arguments or expanded glob values following a bare --icon option. this type of mistake is already a well-understood possibility, and the broadly accepted solution is a standard -- options-terminating sentinel.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant