Changing directory color with zsh + Prezto

Cole Bittel picture Cole Bittel · Oct 16, 2015 · Viewed 7k times · Source

I am using Prezto + zsh as my shell. I would like to change the color of directories when I ls my directory. For instance, here is what I currently have:

My crappy ls listing

Obviously, this is no fun, as I’m hardly able to read my directories because the blue is so dark. I’d like to change it to white or orange or something lighter.

This dark blue is specific only to directories. Files show up in a nice white text. Where and what settings must I find to change this?

Answer

Matt Byrne picture Matt Byrne · Jun 14, 2016

The easier way to do this is to change the colour scheme of your terminal. For example if you are using iTerm2 on a Mac then:

  • Launch iTerm2
  • type CMD+i
  • In the "Colors" tab, change the setting for "Blue" (and potentially the "Bright" equivalient)
  • In the "General" tab, click "Copy Current Settings to Selected Profile"

If you want to revert back to the defaults you can always select a value from the "Color presets..." dropdown in the "Colors" tab.

Do the equivalent in your favourite terminal if you don't use iTerm2 on a Mac.