• MacBook设置终端命令行的颜色高亮显示


    一、颜色高亮显示

    针对terminal采用bash模式:

    1. 编辑 ~/.bash_profile, 加入以下代码:
      export CLICOLOR=1
      export LSCOLORS=gxfxaxdxcxegedabagacad
    2. 保存,然后重启terminal,搞定,恢复正常了.

    详细讲解代码中的涵义:

    1. CLICOLOR: 前景色和背景色的字符串合并值
    2. LSCOLORS: 对于不同变量所采用的颜色方案,具体看如下表格:
      a       black
      b       red
      c       green
      d       brown
      e       blue
      f        magenta
      g      cyan
      h       light grey
      A      bold black, usually shows up as dark grey
      B       bold red
      C      bold green
      D      bold brown, usually shows up as yellow
      E       bold blue
      F       bold magenta
      G     bold cyan
      H      bold light grey; looks like bright white
      x       default foreground or background
      而文件类型列表如下:
      1. directory
      2. symbolic link
      3. socket
      4. pipe
      5. executable
      6. block special
      7. character special
      8. executable with setuid bit set
      9. executable with setgid bit set
      10. directory writable to others, with sticky bit
      11. directory writable to others, without sticky

    所以对照这张表就可以得知:

    gxfxaxdxcxegedabagacad

    就是对于directory而言,它的前景色就是: g(cyan),而背景色就是:x(默认的背景色).

  • 相关阅读:
    CodeForces 404C Restore Graph (构造)
    UVa 1204 Fun Game (状压DP)
    HDU 5038 Grade (水题,坑题)
    mybatis整合Spring编码
    关于Spring MVC写的不错的几篇博客
    SpringMVC配置文件详解:<context:annotation-config/>和<context:component-scan base-package=""/>和<mvc:annotation-driven />
    常见文件下载后缀
    Spring MVC
    Spring
    反射
  • 原文地址:https://www.cnblogs.com/klj123wan/p/4175692.html
Copyright © 2020-2023  润新知