Mac OSX: Cannot color broken symlinks
Install Homebrew first.
- Install GNU coreutils:
brew install coreutils
- Put the following in your
~/.bash_profile
:eval $(gdircolors) alias ls="gls --color=auto"
Open a new shell, and broken links will be highlighted like on Linux.
I don't think it's possible – the man page for ls
doesn't list a color slot for broken symlinks.
Here's a handy find
one-liner for finding broken symlinks:
find -L . -type l -ls