Manjaro linux: syntax/source highlighing/coloring in vim/bash terminal
if you are a text tool user like me, syntax coloring or source code highlighting can be helpful.
# 1. use GUI add/remove software to install 2 packages:
syntax-highlighting
source-highlight
# 2. edit ~/.bashrc and add below
# (if other linux distro, use other path of src-hilite-lesspipe.sh)
export LESSOPEN="| /usr/bin/src-hilite-lesspipe.sh %s"
export LESS=" -R "
alias less='less -m -N -g -i -J --underline-special --SILENT'
# 3. edit ~/.vimrc and add
if &t_Co > 2 || has("gui_running")
syntax on
set hlsearch
endif
* * *
# to test
open a terminal
$ ls
$ less test.cpp
$ less test.py
$ vim test.py