bash_profile: set ls color alias to auto

ls --color emits the color code irrespective of whether it is being
attached to terminal or not. Which might result in color codes being
added to file upon redirection.

auto option with ls --color emits the color codes only the output is
attached to terminal, otherwise the colors are turned off.

Fixes #8993.

Signed-off-by: Ryan Leavengood <leavengood@gmail.com>
This commit is contained in:
Prasad Joshi 2012-09-16 08:59:42 +05:30 committed by Ryan Leavengood
parent 2f5c0cbab1
commit 4fd62caa9a

View File

@ -24,7 +24,7 @@ export LC_COLLATE=$LC_MESSAGES
export LC_CTYPE=$LC_MESSAGES
export LC_MONETARY=$LC_NUMERIC
alias ls="ls --color"
alias ls="ls --color=auto"
alias ll="ls -lA"
alias la="ls -A"
alias m="more"