|
发表于 2004-3-12 22:30:01
|
显示全部楼层
- if [ -f "/etc/dircolors" ] ; then
- eval $(dircolors -b /etc/dircolors)
- if [ -f "$HOME/.dircolors" ] ; then
- eval $(dircolors -b $HOME/.dircolors)
- fi
- fi
- export LS_COLORS
复制代码
首先看看你的shell code有没有写正确。
其实以上这段代码放在~/.bashrc或者~/.bash_profile或者/etc/profile都可,注意到redhat在~/.bash_profile里就有source ~/.bashrc。
~/.bash_profile是登录shell配置文件,只在登录时有效,而~/.bashrc是交互式shell配置文件,当你在X环境下打开一个shell时,就是执行这个文件。注意,终端不等同于shell! |
|