第一步:偏好设置
进入终端-偏好设置-描述文件-文本,在这儿可以设置 Terminal的背景颜色,基本字体颜色,透明度等等,操作步骤如下图:


第二:更改ls时目录显示颜色
1.进入~目录。
cd ~
2.编辑.profile或者.bash_profile配置文件(找到一个就可以了)。
vim .profile
3.按i键进入修改模式,在文件末尾添加以下三行代码。
export LS_OPTIONS='--color=auto' # 如果没有指定,则自动选择颜色
export CLICOLOR='Yes' #是否输出颜色
export LSCOLORS='CxfxcxdxbxegedabagGxGx' #指定颜色
4.按esc键退出修改模式,输入:wq!保存退出,输入下面代码使配置生效。
source .profile
好了,这就OK了。 试试ls。

网友评论