Move alias for ls into lscolors.zsh

Having the ls alias default to `ls --color=auto` caused it to break on
OSX, since the version of ls that ships with OSX doesn't support the
`--color` option.

This change moves the alias into lscolors, since we already have a check
for OSX vs non-OSX (in my case, Linux). This allows the alias to work as
expected on Linux, while the environment variable LSCOLORS provides the
coloring option on OSX.
master
nirenjan 2018-10-23 22:21:19 -07:00
parent 1c412ee7a2
commit 5acbda2aeb
2 changed files with 3 additions and 1 deletions

View File

@ -3,7 +3,6 @@
#######################################################################
# Common aliases across systems
# ls aliases
alias ls='ls --color=auto'
alias ll='ls -l'
# Git aliases

View File

@ -39,6 +39,9 @@ then
# Must use either CLICOLOR=1 or ls -G
export CLICOLOR=1
else
# On Unix, add an alias to display the color always
alias ls='ls --color=auto'
fi
DCFILE="$HOME/.dircolors"