ubuntu 友好终端 字体颜色 shell终端颜色 修改

服务器系统 :  Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-30-generic x86_64)

 

输入命令 :  dircolors -p > /root/.dircolors

输入命令 :  vim /root/.dircolors

修改以下东西:
      NORMAL 01;36       # global default, although everything should be something.
      FILE   00;37       # normal file
      DIR    00;33    # directory
      LINK   03;36    # symbolic link

      #下面可以不设置
      FIFO   40;33    # pipe
      SOCK   01;35    # socket
      DOOR   01;35    # door
      BLK    40;33;01 # block device driver
      CHR    40;33;01 # character device driver
      ORPHAN 41;33;01 # symlink to nonexistent file
      MISSING 01;05;37;41 # ... and the files they point to

存盘,退出vim编辑器

 

输入命令 : vim /etc/profile

       添加 export TERM=xterm-color

 

输入命令 : mv /root/.bashrc /root/.bashrc.bak       (做备份)

输入命令 : vim /root/.bashrc

添加下面:

PS1='\n\033[0;33m[\u@\h]\033[0m  \033[0;31m\w\033[0m  \n\[\e[40;92;01m\]\$ '

shopt -s histappend
HISTSIZE=1000
HISTFILESIZE=2000
shopt -s checkwinsize

# You may uncomment the following lines if you want `ls' to be colorized:
export LS_OPTIONS='--color=always'
eval "`dircolors /root/.dircolors`"
alias ls='ls $LS_OPTIONS'
alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'
alias grep='GREP_COLOR="1;33;40" LANG=C grep --color=always'

# enable color support of ls and also add handy aliases
if [ "$TERM" != "dumb" ]; then
    eval "`dircolors -b /root/.dircolors`"
    alias ls='ls --color=auto'
    alias dir='ls --color=auto --format=vertical'
    alias vdir='ls --color=auto --format=long'
fi

保存,退出vim编辑

 

#source /root/.bashrc

这样就完成了  恭喜你

 

 

 

 

 

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值