Q: Today in Ubuntu 14 normal user SSH login shell found that the LS command to view the directory, the Discovery folder and files are the same color display! This is unreasonable, Linux will be based on the file type is different color display Ah! That looks good!
A: Switch to root, everything is OK. So the conjecture should be a shell setup problem.
Solve: How do I set it up?
VI ~/.BASHRC
#!/bin/bash
if [-x/usr/bin/dircolors]; Then
Test-r ~/.dircolors && eval "$ (dircolors-b ~/.dircolors)" | | Eval "$ (dircolors-b)"
alias ls= ' ls--color=auto '
Alias grep= ' grep--color=auto '
Alias fgrep= ' Fgrep--color=auto '
Alias egrep= ' Egrep--color=auto '
Fi
This line of red is more important. The others are environmental judgments.
~/.dircolors stores the configuration file about the color, so you have to modify it if you want to change the default color.
This article is from the "Shell Settings for Linux" blog, so be sure to keep this source http://9486329.blog.51cto.com/9476329/1876015
Troubleshoot shell setup issues with Linux