I found the solution:
adding a line TERM=dumb in the ~/.dircolors file did the trick, as emacs inferior mode shell type is dumb.
Thanks for all the help getting me close to the answer!
Best,
Yuan
Am 9.1.2012 um 17:43 schrieb Yuan Luo:
Does it work when you use
> All aliases in ~/.bashrc are listed in emacs shells.
> I already had have ansi-color-for-comint-mode-on set.
> execution of ls traces to /bin/ls
/bin/ls --color=auto /bin
/bin/ls --color /bin
manually and directly?
My manual page explains:
With --color=auto, ls emits color codes only when standard output is connected to a terminal. The LS_COLORS environment variable can change the settings. Use the dircolors command to set it.
There is a chance that LS_COLORS hinders ls, it's also possible that in *shell* buffer standard output is not connected to a terminal. The latter seems to be true for me on Mac OS X (10.6.8, Snow Leopard). So by omitting the "=auto" should make your aliases work.
--
Greetings
Pete
Bake pizza not war!