13 lines
285 B
Bash
13 lines
285 B
Bash
ccat(){
|
|
cat $* | sed -u "s/ERROR/$(tput setaf 1)&$(tput sgr0)/gI"|sed -u "s/WARNING/$(tput setaf 3)&$(tput sgr0)/gI"|sed -u "s/INFO/$(tput setaf 2)&$(tput sgr0)/gI"|sed -u "s/DEBUG/$(tput setaf 6)&$(tput sgr0)/gI"
|
|
}
|
|
|
|
ctail(){
|
|
tail $* | ccat"
|
|
}
|
|
|
|
cgrep(){
|
|
grep $* | ccat"
|
|
}
|
|
|