Post

set ls color on FreeBSD and ubuntu

Set ls color on FreeBSD using tcsh

$ echo “alias ls ls -GF” » ~/.cshrc

$ echo “setenv LSCOLORS Cxfxcxdxbxegedabagacad” » ~/.cshrc

$ source ~/.cshrc

ref: about color value, please man ls

Set ls color on ubuntu using bash

$ vi ~/.bashrc

alias ls=’ls -F –color=auto’

$ dircolors –print-database » .dircolors

$ vi .dircolors (change colors you like)

$ source .dircolors

add color support for other file format

ex: export LS_COLORS=$LS_COLORS:”*.wma=01;35”:”*.m4a=01;35”

ref: about color value, http://www.linux-sxs.org/housekeeping/lscolors.html

This post is licensed under CC BY 4.0 by the author.