I'm discovering new file type categories (if one can call different colors in the terminal in such a manner) almost on a daily basis. Still, I haven't found an exhaustive list of all recognized file types (compressed, pipe, directory, music, etc.) and the respective colors on the terminal, and that's a resource I'd appreciate to have. Is there a complete list for any Unix-based system? I'd like a full table for many distros, options, etc.; but if you'd give me a few really useful informative links, perhaps someone can add it up into a table (maybe this should be a community-wiki question, however, I can't mark it as such).

  • 1
    See the output of dircolors -p. That has nothing to do with Unix, that's just default settings for the GNU implementation of ls. Sep 4 '13 at 21:48
  • @Stephane, I knew the colors had to be somewhere in my computer! But you mean all GNU-Linux distros give the same color by default? Also, in other Unix-based systems, is there any color?
    – JMCF125
    Sep 5 '13 at 15:30

You can set the colours for individual file types yourself, using ~/.dir_colors. See this related question: How to colourize the output of ls.

trapd00r's .dir_colors file is a particularly detailed one and will give you a good idea of the range of file types available on Linux systems.

  • I had heard it could be done (although through the terminal's GUI). I'd also like to know about other Unix-based systems, what's their (if any) default ls output color? Also, I'd like to have all those in an answer in a table together with the non-extended version (as @Stephane referred, provided by dircolors) and other normal versions (giving both the numbers representing the color and the same color as foreground).
    – JMCF125
    Sep 5 '13 at 17:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.