a@macbook:~/$ ls ls: illegal option -- - usage: ls [-ABCFGHLOPRSTUWabcdefghiklmnopqrstuwx1] [file ...]
Fix: Check the following files for “ls –color”
alias ls='ls -G' ~/.bashrc, .~/bash_aliases ~/.profile a@macbook:~$ grep -Es "ls\s+--color" ~/.bash* ~/.profile /Users/a/.bash_aliases:#alias ls='ls --color=auto' /Users/a/.bashrc: #alias ls='ls --color=auto'
References
1. https://superuser.com/questions/183876/how-do-i-get-ls-color-auto-to-work-on-mac-os-x
2. http://ninjasingh.blogspot.de/2012/09/ls-illegal-option.html