LS_COLORS

August 19, 2025 ยท View on GitHub

Shell License GitHub stars Stay Amazing

LS_COLORS Logo

This is a color scheme for your terminal, suitable to use as your LS_COLORS environment variable. Most of the colors use the extended color map, described in the ECMA-48 document; in other words, you'll need a terminal with capabilities of displaying 256 colors to take advantage of this.

Some 500+ different filetypes/extensions are supported.

The color scheme of the original repo seemed somewhat random and lacking an overall color philosophy. I decided to rewrite the complete color scheme based on this set of categories:

FILE TYPESCOLOR/FORMATTING
DirectoriesBold light blue
SymlinksBold gray (bold italics pink is orphaned)
System filesUnderlined red
Diff/PatchBright pink (italics/bold)
Files to ignoreDark gray
TextYellow
MarkdownOrange
HTML-type filesBrown
Office-type filesBurgundy-purple
PDF and relatedRed-purple
Media files/imagesPurple
Programming relatedBlue
BinariesBright cyan
ExecutablesGreen
Other file typesWhite

File types within each category can have different shades of that color.

I use this as a sensible alias for ls in my .zshrc:

alias ls='ls --color=always -FH --group-directories-first'

For a consistent color experience between your command line and a curses file manager, you may want to take a look at RTFM.

There is also a corresponding Ranger color scheme included isene.py. This covers only the categories above (no shading of files within a category - with a couple of exceptions) and not all the possible filetypes of the LS_COLORS provided. This will suffice until the Ranger project provides a color scheme that simply parses LS_COLORS instead. To use the isene.py Ranger color scheme, set it in your ranger/rc.conf.

I have also included a linemode plugin for ranger ranger/plugin_linemode.py. Drop this file into your ~/.config/ranger/plugins/ directory and add this line to your ranger rc.conf:

default_linemode classify

Installation

Clone this repo and run the install script install.sh

Note for fish users

Users of the fish shell should source the resulting lscolors.csh file in their config.fish.

What does it look like?

Here's a screenshot with three terminals with ranger running in the left terminal and the other two showing the output of ls:

License

See the original repo.