Browse Source

ctools extended and correction

master
Dirk Alders 1 year ago
parent
commit
8f4ab2582b
1 changed files with 6 additions and 2 deletions
  1. 6
    2
      .zshrc.d/__available__/ctools.zsh

+ 6
- 2
.zshrc.d/__available__/ctools.zsh View File

@@ -2,11 +2,15 @@ ccat(){
2 2
     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"
3 3
 }
4 4
 
5
+cless(){
6
+    ccat $* | less -r
7
+}
8
+
5 9
 ctail(){
6
-    tail $* | ccat"
10
+    tail $* | ccat
7 11
 }
8 12
 
9 13
 cgrep(){
10
-    grep $* | ccat"
14
+    grep $* | ccat
11 15
 }
12 16
 

Loading…
Cancel
Save