athityakumar/colorls

Request to implement a option to change hidden dir/ file colors

Opened this issue · 2 comments

like the title says id really appreciate it, if it would be possible to set a different color for hidden folders and hidden files.

or if thats already a possibility, please point me in the right direction. i set the colors via the darkcolors.yaml file but i didnt found an option for hidden files

@joe23rep - Not sure if we already get the metadata related to whether a file/folder is hidden or not in the FileInfo metadata: https://github.com/athityakumar/colorls/blob/main/lib/colorls/flags.rb#L61

But anyway, we should be able to figure out hidden resources by internally applying the logic:
Hidden files/folders = files/folders shown in colorls -a - files/folders shown in colorls

And once we have a hidden? kind of a property for each file/folder, we can have different colours defined in the YAML and use them here: https://github.com/athityakumar/colorls/blob/main/lib/colorls/core.rb#L364

We'd need a PR for this though. I've added the Hacktoberfest label, incase anyone is interested 😄

I'll fix this @athityakumar @avdv 🤚🏽